all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Visuwesh <visuweshm@gmail.com>
To: Michael Albinus <michael.albinus@gmx.de>
Cc: Robert Pluim <rpluim@gmail.com>,  help-gnu-emacs@gnu.org
Subject: Re: Tramp timeout for currently unreachable connections?
Date: Thu, 12 Sep 2024 23:05:22 +0530	[thread overview]
Message-ID: <871q1o6ahx.fsf@gmail.com> (raw)
In-Reply-To: <87frq4iy6t.fsf@gmx.de> (Michael Albinus's message of "Thu, 12 Sep 2024 19:22:50 +0200")

[வியாழன் செப்டம்பர் 12, 2024] Michael Albinus wrote:

> Robert Pluim <rpluim@gmail.com> writes:
>
> Hi Robert,
>
>>>>>>> On Thu, 12 Sep 2024 16:47:39 +0200, Michael Albinus <michael.albinus@gmx.de> said:
>>
>>     Michael> Visuwesh <visuweshm@gmail.com> writes:
>>     >> Hello all,
>>
>>     Michael> Hi Visuwesh,
>>
>>     >> I know that non-essential=t prevents Tramp from establishing new
>>     >> connections but is there a way to make Tramp use a very short timeout
>>     >> when trying to connect to a previously established connection that is
>>     >> now unreachable?  What I mean is: if I am connected to a remote host via
>>     >> a ssh connection /ssh:user@remote: and my internet connection goes down,
>>     >> I do not want Tramp trying to fetch remote resources forever.
>>
>>     Michael> Use 'M-x tramp-cleanup-connection'. Play with user option `tramp-connection-timeout'.
>>
>> Idle thought: would enabling 'ServerAliveInterval' help at all here?
>> (my Tramp connections travel from one side of my desk to the other, so
>> I canʼt tell ☺️)
>
> Yes, even the Tramp manual speaks about:
>
> 4.19.2 Detection of session hangouts
> ------------------------------------
>
> ‘ssh’ sessions on the local host hang when the network is down.  TRAMP
> cannot safely detect such hangs.  OpenSSH can be configured to kill
> such hangs with the following settings in ‘~/.ssh/config’:
>
>      Host *
>           ServerAliveInterval 5
>           ServerAliveCountMax 2
>
> But who reads manuals ...

Ahh!! It seems I completely misunderstood these two variables in my
initial reading of ssh_config(5) when I was initially reading through
the Tramp manual.  Thank you for pointing this out again.

>> Robert
>
> Best regards, Michael.



      reply	other threads:[~2024-09-12 17:35 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-09-12 14:32 Tramp timeout for currently unreachable connections? Visuwesh
2024-09-12 14:47 ` Michael Albinus
2024-09-12 15:24   ` Visuwesh
2024-09-12 17:27     ` Michael Albinus
2024-09-12 15:27   ` Robert Pluim
2024-09-12 17:14     ` Visuwesh
2024-09-12 17:37       ` Michael Albinus
2024-09-12 17:45         ` Visuwesh
2024-09-12 17:22     ` Michael Albinus
2024-09-12 17:35       ` Visuwesh [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=871q1o6ahx.fsf@gmail.com \
    --to=visuweshm@gmail.com \
    --cc=help-gnu-emacs@gnu.org \
    --cc=michael.albinus@gmx.de \
    --cc=rpluim@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.