awk -F : -v last=${STOP:-0} -v first=${START:-0} '
/^#/ { next; }
NR >= first && (last == 0 || NR <= last) {
print $1, $2, $3, $0
}
' input-file | while read f1 f2 f3 i
do
echo "first field: $f1"
echo "second field $f2"
echo "third field $f3"
echo "whole record (i) $i"
done
Thanks Agama. Having tried the code above, i am getting an EOF error. Can you please explain what the awk is doing and if the format of the code is correct? I am getting the following error
Quote:
unexpected EOF while looking for matching `"'
---------- Post updated at 06:48 PM ---------- Previous update was at 05:36 PM ----------
Hi Agama,
I am unfamiliar with the syntax of the belwo code that you provided. I am getting an error from the code. Can you please let me know if the format of the code is correct? Thanks in advance.
Code:
awk -F : -v last=${STOP:-0} -v first=${START:-0} '
/^#/ { next; }
NR >= first && (last == 0 || NR <= last) {
print $1, $2, $3, $0
}
' input-file | while read f1 f2 f3 i
do
I'm trying to pass a filename, or all the files in the current directory to the ls command with a script. Unsuccessful so far, here are a few of my attempts:
#!/bin/ksh
read fname
#if (( $# > 0 )); then
$fname | ls -l
#fi
this produces a long listing of all the files in my current... (4 Replies)
Hi, so Im a bit new to shell scripting and want to do the following but not sure how. Basically I have a file named "output" which contains misc text but inside the file I want to set up variables like $1 or some symbol. Anyways, in another file called "list" I have a list of items that I want to... (11 Replies)
Hi,
I have a script which adds the user credentials to an ldap server. Im passing the variables as below..
/path/my_script $uname $pwd $environ ${deposit}
If i enter some special characters like ';' in $pwd, script returns an error which is set to display if the user enters... (5 Replies)
Hi
I have a script to which I pass multiple arguments, for example lets say the script name is "abc". I run the script like
./abc def /file <directory location>
In the above "def" is the first argument and "/file" is the second argument. I expect <directory location> that is passed after... (4 Replies)
I have a shell script which is invoked by passing an argument. The outer shell script calls another subshell and I want the argument passed down to flow down to the subshell.
E.g
Invoking a shell ======>> abc_refresh.ksh NM
Below is the content of abc_refresh.ksh
Value1=$1... (7 Replies)
I need to pass arguments to a shell script.My batch is calling some java program.
#################
x=$1
y=$2
java -classpath program
###################
if first parameter and second parameter is null then
java -classpath program
if first parameter is not null and second parameter is... (3 Replies)
I have noticed this thing using csh when passing arguments
Suppose I call a csh script using
../Scripts/plot-model.csh -vmod="npt02-z30.vmod" -R="0/80/0/30" -c="0/4.5" -aspr="1:10"
Somehow the " get removed when doing
$argv
ending up with
-vmod=npt02-z30.vmod... (0 Replies)
hi All,
i am trying to pass arguments that contain space , value will be stored in variables to be used further in script , i went thru previous posting , still its not clear to how to implement for my case.
passing 3 args
test.sh it is 'fun to work in unix'
inside shell
... (3 Replies)
I have a script test.sh which reads various inputs from a user.
#!/bin/ksh
read x
read y
read z
echo x: $x y: $y z: $z
# read few more things again
read a
read b
echo a: $a b: $b
When i run this script as
test.sh << EOF
1
2
EOF (3 Replies)
Hi,
I am using awk here.
Inside an awk script, I have a variable which contains a very long XML data in string format (500kb).
I want to pass this data (as argument) to curl command using system function.
But getting Too many arguments error due to length of string data(payloadBlock).
I... (4 Replies)
Discussion started by: cool.aquarian
4 Replies
LEARN ABOUT DEBIAN
ipnadminep
IPNADMINEP(1) BP executables IPNADMINEP(1)NAME
ipnadminep - administrative endpoint task for the IPN scheme
SYNOPSIS
ipnadminep
DESCRIPTION
ipnadminep is a background "daemon" task that receives and processes administrative bundles (all custody signals and, nominally, all bundle
status reports) that are sent to the IPN-scheme administrative endpoint on the local ION node, if and only if such an endpoint was
established by bpadmin. It is spawned automatically by bpadmin in response to the 's' (START) command that starts operation of Bundle
Protocol on the local ION node, and it is terminated by bpadmin in response to an 'x' (STOP) command. ipnadminep can also be spawned and
terminated in response to START and STOP commands that pertain specifically to the IPN scheme.
ipnadminep responds to custody signals as specified in the Bundle Protocol specification, RFC 5050. It responds to bundle status reports
by logging ASCII text messages describing the reported activity.
EXIT STATUS
0 ipnadminep terminated, 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 ipnadminep.
1 ipnadminep was unable to attach to Bundle Protocol operations or was unable to load the IPN scheme database, probably because bpadmin
has not yet been run.
FILES
No configuration files are needed.
ENVIRONMENT
No environment variables apply.
DIAGNOSTICS
The following diagnostics may be issued to the ion.log log file:
ipnadminep can't attach to BP.
bpadmin has not yet initialized BP operations.
ipnadminep can't load routing database.
ipnadmin has not yet initialized the IPN scheme.
ipnadminep crashed.
An unrecoverable database error was encountered. ipnadminep terminates.
BUGS
Report bugs to <ion-bugs@korgano.eecs.ohiou.edu>
SEE ALSO bpadmin(1), ipnadmin(1), bprc(5).
perl v5.14.2 2012-05-25 IPNADMINEP(1)