Search Results

Search: Posts Made By: haaru
4,925
Posted By haaru
Variable scope in bash
Hello! Before you "bash" me with
- Not another post of this kind
Please read on and you will understand my problem...

I am using the below to extract a sum of the diskIO on a Solaris server.
...
5,800
Posted By haaru
I havent tested it but try: ...
I havent tested it but try:



RES=$(ps -e | grep $1 | awk '{print $1}')

#This checks if the result of the command is not null
if [ -n "$RES"]; then
kill $RES
fi


You can...
Showing results 1 to 2 of 2

 
All times are GMT -4. The time now is 10:20 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy