![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| doubt in awk | jisha | Shell Programming and Scripting | 4 | 04-16-2008 04:02 AM |
| AWK doubt | Rafael.Buria | Shell Programming and Scripting | 2 | 02-06-2008 11:00 AM |
| awk doubt | Pradee | Shell Programming and Scripting | 3 | 11-15-2007 10:35 AM |
| ftp doubt | ranj@chn | Shell Programming and Scripting | 0 | 01-04-2006 08:47 AM |
| doubt in sed | matrixmadhan | UNIX for Dummies Questions & Answers | 3 | 08-03-2005 11:34 AM |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
One doubt
Hi,
Can i use the shell script like this? When i am running the script it is hanging not giving me any output. I can redirect the output and then i can do the manipulations also but why this one is wrong. I am confused we can do like this or not.. Code:
#!/usr/bin/ksh
for line in `top`
do
cpuusage=`echo $line | cut -d " " -f7`
memusage=`echo$line | cut -d " " -f12`
echo "cpuusage is $cpuusage"
echo "memusage is $memusage"
done
Last edited by namishtiwari; 06-27-2008 at 09:12 AM.. |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|