Shell timeout value is not effective


I am using a Plink to run a remote command with Xojo shell(mode=0 / TimeOut=150000).
With a remote machine(Linux) shutdown, I tried to run the shell but I got ‘host is not reachable’ error just in 45 seconds even though a shell time out is set to 150s.

Do you have any idea why it is timed out at 45 seconds?


Without Plink, I also tested a simple remote command with MBS SSH plug in, the same issue happened.
The timeout error just occurred in 20s. I noticed that Plink test took 45 seconds as there are 2 part using Plink.

Probably, there is a timeout limit in SSH connection like KeepAlive?

I have no idea what a Plink is, but might it be a dns lookup failure? Or the remote refusing the connection? Or suchlike?

Intentionally, I did shutdown the remote machine for the test.
The reason of this test is to implement some codes in case SSH connection is lost or when it is very slow.

I guess there might be a default value of timeout. I am checking the MBS Plugin manual now.

It seems that there is a default value of TCP/IP like below.
link text

It says:
The TCP three-way handshake is limited to a 21-second timeframe (3 seconds + 23 seconds + 43 seconds = 21 seconds).

It is very similar to my test with Plink & MBSPlugin.

Do you think so? Unfortunately, I have no idea to change the default value in Plink but there seems to be in MBSPlugin.

If the Shell is timing out, you wouldn’t get any message at all. The fact that you’re getting a message means that the Shell timeout is functioning properly. It’s the command (Plink) itself that is timing out. It has nothing to do with the Shell settings.

Yes, before I got Shell time out, apparently there is a Plink time out and I realized that there is a default value of Tcp/IP timeout in Windows. 20 seconds.
So, I got time out signal in just 20 seconds.

Thank you.