|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Get inside! Sample the range of functionality easily built with JMSL Library for Time Series Data Analysis, Heat Maps, Portfolio Optimization, Monte Carlo Simulation, Stock Price Charting and more. Download Now! |
|
#1
|
|||
|
|||
|
Help w/ script (checking systems up/down)
I am new to here. Hopefully, I don't say or write something stupid.
------------------------------------------------ Anyway, i got this script question. I have to write a script to check for block of ip addresses of server (192.168.1.1-254) If the system is up, check the uptime and disk space. Record the finding. If the system is down, e-mail admin with the list of systems. If the system is not UNIX, skip. ------------------------------------------------ I can perform the ip lookup and ping to verify the system up and down, but how to verify the system is UNIX or other? Also, how to check the systems' uptime and disk space remotely? Thanks in advance. |
|
#2
|
|||
|
|||
|
this is OK: ping to verify the system up and down
this is the probl: but how to verify the system is UNIX 'ssh' does this: how to check the systems' uptime and disk space remotely? Q: on wich OS runs the script ? apart from ftp and telnet (they give in banner the os-type of remote sys) i cannot remember any other cmd giving this info. by ftp|telnet you get 2 other probls: - how to quit them in NOT interactive mode, i mean: input of ^D, quit, bye or exit. - you need to know ALL banner of differents *nix OS you could try 'expect' (you need a user on rem sys) i would: - put this info manually (once) in your ip-list - delete non *nix ip from the list - by new installs, organize better your ip, say odd-ip = *nix or group them aa.bb.cc.[x-y] = *nix alternatively, reverse the problem, let the remote sys (over cron) send you the infos. this suppose the script is installed on rem-sys, but you do it once. finally the best way is 'nis', - an extra nickname in 'hosts' table. - put the required info direct in a special table. ![]() Last edited by guggach : September 7th, 2004 at 09:25 PM. Reason: typo |
|
#3
|
|||
|
|||
|
Thank you very much. I guess i will go with Expect. Consider the script might need to check on some network gears. Those devices have telnet ability.
The reason I am not running this from all the systems has to do with central control, and some of the systems are network device, like Cisco. Thanks for the suggestion. By the way, how can I capture the information from Expect back to script? |
![]() |
| Viewing: Dev Shed Forums > Operating Systems > UNIX Help > Help w/ script (checking systems up/down) |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|