Languages and Scripting
cancel
Showing results for 
Search instead for 
Did you mean: 

script for checking uptime

tempsample
Frequent Advisor

script for checking uptime

HI,

 

I need to know is it possible to check uptime for multiple server.

 

for example :from server A, I need to check the uptime of server B,C,D,E in a html format.

 

Can I have some idea ?

7 REPLIES
Ajin_1
Valued Contributor

Re: script for checking uptime

Hi

 

Write a script

 

ssh x ,y,z and then check the uptime

Thanks & Regards
Ajin.S
Proverbs 3:5,6 Trust in the Lord with all your heart and lean not on your own understanding; in all your ways acknowledge him, and he will make all your paths straight.
JuanCBarrios
Occasional Advisor

Re: script for checking uptime

from server A:

 remsh <server B> -n 'uptime'

 

or 

ssh <server B> -n 'uptime'

tempsample
Frequent Advisor

Re: script for checking uptime

hi,

 

I want the output to display in a html format.

 

 

Dennis Handly
Acclaimed Contributor

Re: script for checking uptime

>I want the output to display in a html format.

 

Then you may want to look at some perl scripting.

tempsample
Frequent Advisor

Re: script for checking uptime

hi

 

can you share me a sample script ?

Bill Hassell
Honored Contributor

Re: script for checking uptime

For HTML, just insert <PRE> before the output from uptime and </PRE> after the output.

 

If you are looking for a complete web page that identifies the server name, date and time, etc, you need to read  about how to create web pages.



Bill Hassell, sysadmin