Does anyone know how I can write a script in AIX to group together useful health-check commands like df -k, lssrc -a, ps -eaf | grep informix, ipcs -mt, netstat -i, lpstat ??
Cheers
Rob
Does anyone know how I can write a script in AIX to group together useful health-check commands like df -k, lssrc -a, ps -eaf | grep informix, ipcs -mt, netstat -i, lpstat ??
Cheers
Rob
The older I get, the faster I was.
Erm, just stick them in a file and make the file executable...
So make a file (in vi or emacs or whatever) and list them line by line so:
Then make the file executable:Code:df -k lssrc -a ps -eaf | grep informix ipcs -mt netstat -i lpstat
chmod u+x <filename>
then run it with ./<filename> or stick it in your PATH and just run it with the filename. Should work.
"All our beliefs are being challenged now, and rightfully so, they're stupid." - Bill Hicks
Thanks v much, it works a treat. Can you explain how to add to PATH though........
How do create your sig pics?
Cheers
Rob
The older I get, the faster I was.
To add it to the PATH, it depends what shell you are running. I've not used AIX before...If you finger yourself it should tell you, so:
finger <username>
If it's bash, you need to edit your .bash_profile and add
export PATH=$PATH:<full path to script>
so if the script is in /home/robbiehall/scripts you need to add
export PATH=$PATH:/home/robbiehall/scripts
If you are using another shell, it's probably a matter of editing .profile, but it would depend on the shell.
My sig image - you mean how did I create the actual image, or how did you get the forum to display it?
"All our beliefs are being challenged now, and rightfully so, they're stupid." - Bill Hicks
Well both I spose...
I mean I guess you use photoshop or similar to manipulate the images..what are the optimum sizes w.h.y. ?
and yes how does the forum display it...?
is it then necessary to upload to my website, or their own web space, or simply paste into a signature box somewhere in my profile?
Ceers
Rob
The older I get, the faster I was.
Yeah. er, just use paint shop pro or whatever to make the image. Make it small kbytes wise and ensure that the dimensions are no bigger than anyone elses, then upload it to your webspace. Then you can just edit your profile and do something like:
[ img ]http://www.bennyr.pwp.blueyonder.co.uk/sig.gif[/ img ]
(Take the spaces out of the IMG tags tho - I had to add them in to stop the forum displaying an image...
"All our beliefs are being challenged now, and rightfully so, they're stupid." - Bill Hicks
There are currently 1 users browsing this thread. (0 members and 1 guests)