![]() |
|
|
|
|
|||||||
| Forums | Portal | Register | Forum Rules | FAQ | Contribute | Members List | Arcade | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts here. |
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| How to set the timeout for the client | shilpi_gup | High Level Programming | 1 | 10-24-2005 01:25 AM |
| DCE Authentication timeout value in aix. | prabhuv | AIX | 0 | 07-26-2005 03:03 AM |
| About the Timeout | lyh003473 | SUN Solaris | 4 | 07-24-2004 06:12 PM |
| timeout | csaunders | HP-UX | 5 | 02-27-2004 07:54 AM |
| how to set timeout for aix? | ichiro | UNIX for Dummies Questions & Answers | 3 | 01-27-2004 03:36 PM |
|
|
Submit Tools | LinkBack | Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
ssh/scp - can you specify timeout?
I am scp'ing a file from a server (servera) to my server (serverb)
If servera is down - the scp never times out ... it just hangs eternally.. It is possible to specify a timeout in my script - so if scp fails/hang for more than 60 seconds I assume its failed ? I am aware there is some timeout value I can set on servera in the sshd_config file on servera but I would prefer if I could include some sort of timeout in my script running on serverb Example command: scp user1@servera:testdir/test.log /logs |
| Forum Sponsor | ||
|
|
|
#2
|
|||
|
|||
|
Quote:
Is the machine on the same subnet? Is there a firewall suppressing ICMP messages? |
|
#3
|
|||
|
|||
|
Its on a different subnet....
Not sure if its suppressing messages or not |
|
#4
|
|||
|
|||
|
If your using OpenSSH then use the ConnectTimeout option
Code:
scp -o ConnectTimeout=30 user1@servera:testdir/test.log /logs |
|||
| Google The UNIX and Linux Forums |
| Thread Tools | Search this Thread |
| Display Modes | |
|
|