Operating System - HP-UX
1752805 Members
5305 Online
108789 Solutions
New Discussion

Re: setting timeout value

 
tempsample
Frequent Advisor

setting timeout value

Hi

 

   for HOST in $(< /tmp/hostdetails.txt); do
   echo $HOST
   ssh  $HOST uptime | awk -F, '{sub(".*up", "", $1);print $1,$2}'
   done >> uptime.log

 

suppose if a host is unavailable  during uptime check,it should skip that particular host and check for the other server.

 

How can i make those time setting value ?

 

 

1 REPLY 1
Dennis Handly
Acclaimed Contributor

Re: setting timeout value

>How can I make those time setting value?

 

Try -o ConnectTimeout=##

-o option
Can be used to give options in the format used in the configuration file.  This is useful for specifying options for  which there is no separate command-line flag.  For full details of the options listed below, and their possible values, see  ssh_config(5).