10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
Now I'm trying summary sar data.
CPU , Memory , Traffic , TPS (Min Max value)
CPU is okay using below command.
$ sar -p | awk '{gsub(//,"")}1' | awk 'BEGIN {min=1000000; max=0;};\
{ if($7<min && $7 != "") min = $7; if($7>max && $7 != "") max = $7; } END {print min, max}'
98.93 99.55
... (1 Reply)
Discussion started by: tom8254
1 Replies
2. Shell Programming and Scripting
I have a file that I need to find each interface that has move-group on the interface line and print this line if the lines under the interface does Not have "filter-shared 14".
Example file:
interface 1/1/1/0 move-group
decription one one one zero
no shut
filter-shared 14... (21 Replies)
Discussion started by: numele
21 Replies
3. Shell Programming and Scripting
I have a lines like below, captured from rrdtool fetch command,
1395295200 2.0629986254e+06 7.4634784967e+05
1395297000 2.0198121616e+06 6.8658888903e+05
1395298800 1.8787141122e+06 6.7482866452e+05
1395300600 1.7586118678e+06 6.7867977653e+05
1395302400 1.8222762151e+06 7.1301678859e+05I'm... (3 Replies)
Discussion started by: rk4k
3 Replies
4. Shell Programming and Scripting
Input:
9999~cbc~100~209~ozzxczcz~10001001001~100~abc10
123~a~sdklfjl~sldoi~~~ksjdfnkjsdf~123456
125~g~sdklfjl~slsdfsdfsdfsdfdoi~~~~~~~~ksjdfnkjsdf~345
127~wera~sdklfjl~sldoi~~~ksjdfnkjsdf~123
128~awer~swerwerdklfjl~sldoi~~~ksjdfnkjsf~1da2345... (7 Replies)
Discussion started by: onesuri
7 Replies
5. Shell Programming and Scripting
Hi all,
I have script to monitor and sum up the total memory use up for each individual process.
proc=$1
svmon -P -O summary=basic,unit=MB|awk 'NR>4'|grep -w "${proc}" |awk '{sum+=$3} END {printf "\t" sum """\n";}'
But I would like the script to be able to display as following
... (3 Replies)
Discussion started by: ckwan
3 Replies
6. Shell Programming and Scripting
Hi
can print command in awk take the variable and write its value in the file?
Excerpt from my shell script. for some reason, $proc is being written in the file instead of its value. can someone tell me what is the issue?
for proc in EH LOGEV
do
echo $proc
./plist -P $proc |... (2 Replies)
Discussion started by: lookinginfo
2 Replies
7. Shell Programming and Scripting
Hello Team,
I have written following command which is giving output is as shown below.
bash-3.00$ grep -i startup catalina.out | tail +2 | sed -n 1p | awk -F" " '{ for (x=1; x<=5; x++) { printf"%s\n", $x } }'
Dec
19,
2010
3:28:39
PM
bash-3.00$
I would like to modify above command to... (2 Replies)
Discussion started by: coolguyamy
2 Replies
8. Shell Programming and Scripting
half of the problem is already solved with the help of bartus11 suggestion
I have a txt file having rows and coulmns, i want to perform some operation on a specific coulmn starting from a specific line.
50.000000 1 1 1
1000.00000
1000.00000
... (5 Replies)
Discussion started by: shashi792
5 Replies
9. UNIX for Advanced & Expert Users
894344202808090;11122;040320 075858 166;101;0;0;10u;0;NA;65;221890;2;101973;185059;568674;Y; PRE;0;0;NA;NA;0;NA;0;NA;textmsg;textmsg_snd1;telusmob;TEXTMSG1;0.15000000;126037;2010/03/04 12:58:57gmt;0;70532192;
plz tell me any awk command
which on the basis of the yellow field which is... (1 Reply)
Discussion started by: madfox
1 Replies
10. Shell Programming and Scripting
Hello Experts,
I am back, with another doubt. I am not sure what it relates to this time - awk or the print command actually. I'll explain the scenario:
I have a huge file, and it has some traces(logs). In between those logs, there are statements with some SQL queries. All I want to do is... (4 Replies)
Discussion started by: hkansal
4 Replies