BEGIN {
# if no action is specified on the command line - default to "print"
if (action == "")
action="print"
}
{
if ( action == "print" )
doPrint
if ( action == "forward" )
doForwarding
if ( action == "whatever" )
doWhatever
}
Hi Friends,
Can any of you explain me about the below line of code?
mn_code=`env|grep "..mn"|awk -F"=" '{print $2}'`
Im not able to understand, what exactly it is doing :confused:
Any help would be useful for me.
Lokesha (4 Replies)
hi,
i have a file having datas like that
./a.txt
12344
12345
12346
12347
.....
.....
...
i want to save this datas to another file like that
./b.txt
12344 12345 12346 12347 ... ... ...
i think awk can make this but how? :) waiting for ur help. (3 Replies)
Hi,
I have line in input file as below:
3G_CENTRAL;INDONESIA_(M)_TELKOMSEL;SPECIAL_WORLD_GRP_7_FA_2_TELKOMSEL
My expected output for line in the file must be :
"1-Radon1-cMOC_deg"|"LDIndex"|"3G_CENTRAL|INDONESIA_(M)_TELKOMSEL"|LAST|"SPECIAL_WORLD_GRP_7_FA_2_TELKOMSEL"
Can someone... (7 Replies)
Hello...
I'm trying to setup a cronjob to record system data using glance at certain times of the day. My question is, how would one export the "Global System Calls" information to a file? Below is the command I have been using and it works to export CPU information.
glance -f ... (0 Replies)
logs:
"/home/abc/public_html/index.php"
"/home/abc/public_html/index.php"
"/home/xyz/public_html/index.php"
"/home/xyz/public_html/index.php"
"/home/xyz/public_html/index.php"
how to use "cut" or "awk" or "sed" to get the following result:
abc
abc
xyz
xyz
xyz (8 Replies)
Discussion started by: timmywong
8 Replies
8. Post Here to Contact Site Administrators and Moderators
Majority of the questions are pertaining file/string parsing w.r.t
sed
or
awk
It would be nice to have these two as their own sub category under shell-programming-scripting which can avoid lot of duplicate posts. (1 Reply)
Hi Experts,
I have a string with colon delimited, want 2nd colon to be changed to a pipe.
data:
101:8:43:4:72:14:41:69:85:3:137:4:3:0:4:0:9:3:0:3:12:3:
I am trying with sed, but can change only 1 occurance:
echo "101:8:43:4:72:14:41:69:85:3:137:4:3:0:4:0:9:3:0:3:12:3:" | sed 's/:/|/2'... (5 Replies)
Hello.
System : opensuse leap 42.3
I have a bash script that build a text file.
I would like the last command doing :
print_cmd -o page-left=43 -o page-right=22 -o page-top=28 -o page-bottom=43 -o font=LatinModernMono12:regular:9 some_file.txt
where :
print_cmd ::= some printing... (1 Reply)
Discussion started by: jcdole
1 Replies
LEARN ABOUT MOJAVE
tc-connmark
Connmark retriever action in tc(8) Linux Connmark retriever action in tc(8)NAME
connmark - netfilter connmark retriever action
SYNOPSIS
tc ... action connmark [ zone u16_zone_index ] [ CONTROL ] [ index u32_index ]
CONTROL := { reclassify | pipe | drop | continue | ok }
DESCRIPTION
The connmark action is used to restore the connection's mark value into the packet's fwmark.
OPTIONS
zone u16_zone_index
Specify the conntrack zone when doing conntrack lookups for packets. u16_zone_index is a 16bit unsigned decimal value.
CONTROL
How to continue after executing this action.
reclassify
Restarts classification by jumping back to the first filter attached to this action's parent.
pipe Continue with the next action, this is the default.
drop
shot Packet will be dropped without running further actions.
continue
Continue classification with next filter in line.
pass Return to calling qdisc for packet processing. This ends the classification process.
index u32_index
Specify an index for this action in order to being able to identify it in later commands. u32_index is a 32bit unsigned decimal
value.
SEE ALSO tc(8)iproute2 11 Jan 2016 Connmark retriever action in tc(8)