I think the correct output in this case should be:
Because you cannot determine whether first record (IMAGINE) is correct or not, as you don't have previous record to analyze response. Try this script:
Run it like this: ./script.pl your_file
Hi,
I have below awk statement and I need to convert the second field ( substr($0,8,6))from minutes to hours with 2 decimail place. How can I achieve this?
/usr/bin/awk '{print substr($0,23,4),substr($0,8,6)}' /tmp/MANAGER_LIST.$$ >> /tmp/NEWMANAGER_LIST.$$
Thanks for any help! (4 Replies)
i have a line like this in my script
IP=`get_IP <hostname> | awk '{ print $1 }'
echo $IP
the problem is get_IP <hostname> returns data formated as follows:
ip 1.1.1.1 name server_name
the code above returns
1.1.1.1 server_name and i just need the 1.1.1.1
I have tried to add "|... (5 Replies)
Is there any awk command to calculate P Value ?(Probability)
Is it possib;e to calculate P va;ue for this data for ex?
7.891284
8.148193
7.749575
7.958188
7.887702
7.714877
8.141548
7.51845
8.27736
7.929853
7.92456
8.249126
7.989113
8.012573
8.351206 (2 Replies)
Hello, I have the following file, but one of his columns is not in place, and tried with SED and AWK, how I can correct format?
In the second line break is wrong, and puts it after the first column of next line
I would appreciate if you could guide me on the subject. (4 Replies)
Hello,
I have been trying to use an awk script to parse out correct and incorrect answers in a simple tab-delimited text file. I am trying to compare the user's response to the stimulus presented (in this case, an arrow pointing left or right; e.g., "<--" vs. "-->"). I have the data for the... (6 Replies)
I have this input.|user1 |10.10.10.10 |23|046|1726 (212) |0
|user2 |10.10.10.11 |23|046|43 (17) |0
|test |10.10.10.12 |23|046|45 (10) |0
|test1 |10.10.10.13 |23|046|89 (32) |0
I need to get the data for a user like thisuser1 1726
user2 43
test 45
test1 89... (11 Replies)
Hi all,
I think so I’m getting the result is wrong, while using following awk commend,
colval=$(awk 'FNR>1 && NR==FNR{a=$4;next;} FNR>1 {a+=$4; print $2"\t"a/3}'
filename_f.tsv filename_f2.tsv filename_f3.tsv)
echo $colval >> Result.tsv
it’s doing the condition 2 times, first result... (5 Replies)
Hi everyone,
The following piece of awk code works fine if I use eval builtin
var='$1,$2'
ps | eval "awk '{print $var}'"
But when I try to knock off eval and use awk variable as substitute then I am not getting the expected result
ps | awk -v v1=$var '{print v1}' # output is $1,$2
ps |... (4 Replies)
The awk below runs and produces the following output on the file2. This is just an example of the format as the file is ~14MB. file1.txt is attached. I am trying to count the ids that match between the two files and out the ids that are missing. Thank you :).
file2
970 NM_213590 ... (2 Replies)
Discussion started by: cmccabe
2 Replies
LEARN ABOUT DEBIAN
stcpcli
STCPCLI(1) BP executables STCPCLI(1)NAME
sstcpcli - DTN simple TCP convergence layer input task
SYNOPSIS
stcpcli local_hostname[:local_port_nbr]
DESCRIPTION
stcpcli is a background "daemon" task comprising 1 + N threads: one that handles TCP connections from remote stcpclo tasks, spawning
sockets for data reception from those tasks, plus one input thread for each spawned socket to handle data reception over that socket.
The connection thread simply accepts connections on a TCP socket bound to local_hostname and local_port_nbr and spawns reception threads.
The default value for local_port_nbr, if omitted, is 4556.
Each reception thread receives bundles over the associated connected socket. Each bundle received on the connection is preceded by a
32-bit unsigned integer in network byte order indicating the length of the bundle. The received bundles are passed to the bundle protocol
agent on the local ION node.
stcpcli is spawned automatically by bpadmin in response to the 's' (START) command that starts operation of the Bundle Protocol; the text
of the command that is used to spawn the task must be provided at the time the "stcp" convergence layer protocol is added to the BP
database. The convergence layer input task is terminated by bpadmin in response to an 'x' (STOP) command. stcpcli can also be spawned and
terminated in response to START and STOP commands that pertain specifically to the STCP convergence layer protocol.
EXIT STATUS
0 stcpcli terminated normally, for reasons noted in the ion.log file. If this termination was not commanded, investigate and solve the
problem identified in the log file and use bpadmin to restart stcpcli.
1 stcpcli terminated abnormally, for reasons noted in the ion.log file. Investigate and solve the problem identified in the log file,
then use bpadmin to restart stcpcli.
FILES
No configuration files are needed.
ENVIRONMENT
No environment variables apply.
DIAGNOSTICS
The following diagnostics may be issued to the ion.log log file:
stcpcli can't attach to BP.
bpadmin has not yet initialized Bundle Protocol operations.
No such stcp duct.
No STCP induct matching local_hostname and local_port_nbr has been added to the BP database. Use bpadmin to stop the STCP convergence-
layer protocol, add the induct, and then restart the STCP protocol.
CLI task is already started for this duct.
Redundant initiation of stcpcli.
Can't get IP address for host
Operating system error. Check errtext, correct problem, and restart STCP.
Can't open TCP socket
Operating system error. Check errtext, correct problem, and restart STCP.
Can't initialize socket
Operating system error. Check errtext, correct problem, and restart STCP.
stcpcli can't create access thread
Operating system error. Check errtext, correct problem, and restart STCP.
BUGS
Report bugs to <ion-bugs@korgano.eecs.ohiou.edu>
SEE ALSO bpadmin(1), bprc(5), stcpclo(1)perl v5.14.2 2012-05-25 STCPCLI(1)