From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Michael Albinus Newsgroups: gmane.emacs.help Subject: Re: Tramp timeout for currently unreachable connections? Date: Thu, 12 Sep 2024 19:22:50 +0200 Message-ID: <87frq4iy6t.fsf@gmx.de> References: <87ed5p54dx.fsf@gmail.com> <877cbhj5dg.fsf@gmx.de> <87plp8lwo2.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="14737"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: Visuwesh , help-gnu-emacs@gnu.org To: Robert Pluim Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Thu Sep 12 19:23:19 2024 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1sonXL-0003iF-Op for geh-help-gnu-emacs@m.gmane-mx.org; Thu, 12 Sep 2024 19:23:19 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sonWz-0001qP-Gz; Thu, 12 Sep 2024 13:22:57 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sonWx-0001oA-2s for help-gnu-emacs@gnu.org; Thu, 12 Sep 2024 13:22:55 -0400 Original-Received: from mout.gmx.net ([212.227.15.18]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sonWv-0003Xw-Ec for help-gnu-emacs@gnu.org; Thu, 12 Sep 2024 13:22:54 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmx.de; s=s31663417; t=1726161770; x=1726766570; i=michael.albinus@gmx.de; bh=cGPySDSTJ3Eskwajpfx7IevKH4FYblJUbIyJQny9CZ8=; h=X-UI-Sender-Class:From:To:Cc:Subject:In-Reply-To:References:Date: Message-ID:MIME-Version:Content-Type:Content-Transfer-Encoding:cc: content-transfer-encoding:content-type:date:from:message-id: mime-version:reply-to:subject:to; b=LXzQdXbn5lgnqYDtKttt9HXY0xsyrHb36HOLUxfY008PgwW0m9qV4QNMZYuXooL1 PA1jq+bdq4rIF122AHnhfptDVzVGpjtD75BMcpEq4a7biVOo05HIMArKgWn6+sHoZ ZXrZnYGjp+Nw+88ik5xICp9ImyA3MTfM/MAmLxW5wlC8JiVVxZTvgBBAqZsKrhMJu qIFUyzaFT27oCTE4CR//THIL9ucGG5XQb9n/Mj7IZwnZj2F2a6SZnND7/qYqlm7pf 3B+rdeepxL9iz7++xWpstaiDTzobQ6gJ3+ll/oO0o47pAmLVZmHtDLTAncQc4cnrM 0Wn+mltl7QZ8uhCXJQ== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Original-Received: from gandalf.gmx.de ([185.89.38.155]) by mail.gmx.net (mrgmx004 [212.227.17.190]) with ESMTPSA (Nemesis) id 1Mwwdl-1s40Mz2m0h-011gQs; Thu, 12 Sep 2024 19:22:50 +0200 In-Reply-To: <87plp8lwo2.fsf@gmail.com> (Robert Pluim's message of "Thu, 12 Sep 2024 17:27:25 +0200") X-Provags-ID: V03:K1:vbmphq8fu3pdD80cp4IOhoCFY1r90sLfylnMHRIIbtIFJHGN7ux to8863xyyc5n3O3UUtb7w5FIe47lB+hP+BPkVYcT7nPK5/0ASBFtyt95k06iGqKvaYnh8nK yN10r4bxWhro2j5uHmeb8sb/k32JfzpYRCqqerYFLmJrFv4M707rbVkqEvDQjuZMreBvcCE ZwYHXkN/ZUPrQiJTUhh8Q== UI-OutboundReport: notjunk:1;M01:P0:OoFbhQ67BNI=;FmbN86LCoyZq1GpqcoyESkZ8OmK W9uFbZ180b99AUBD81uoBslcjgeljiIh0g+3kQoF8iYzWkdPnTZ8Ag5SEtlwvlYB6C8r2+5Az YK3plI9izDHaxRFvoYi4Fypx2Nv24CYl3NfdTHtJh94xogcttuWqqHFchF15qxW4JnSVkoVA+ WMqoJFkpYWDbth+hYlH9fHeoQgdzFJ3x+YBDAMn5O67Zoq6mn20Rls5st98pvJwxEn8JpvGrA kK9lTOdwRzF8Uak4gM2z8mXx/N7xVsliNIBqTYVFLxGNK3AJRxM6goL9MdtpIDeBu2SuefGSd sAa16btCDRh8GLBF7yCR8MiUUuMaC93ANOykfy/3k+Bb/jfVN1DnCj/GS5yVlKbmrQe4O5AT9 pUtV5BqNnlxcogjdT2bIrI7OGCKYLtE3/npdbGrYi56V2UrhSl3CQk/W0Rnyo0wwSvR2AKJDn AJmGoKezJ6le1SIqQ6RxdPjMC5QWuYugm6mFXz4eAlkzdTgN9jGnZauR0lhCFu1IcYFCEgrar FCfFsaGC1UeuFoOIgdTuk6NFlyDfdYruhynunhBWgH/XQnx7og4Cp9sUlw2DScqddnJkMdPnM oxJ3f+0AMQe2EaRTtoBh3zeULqR0mq/bkCQwKwRz4jW146CNyjgHhNaRMJh05UFSkv7uxQ7Fb nhDZhwBQCDAR13x8Khr9kMrKTLM6YK+++3pNGrVvBkprg44MHmqU1EOalZLxy2kD5LpH8Okgl ZJ5D18YBd7zgrKzzRsGQZ3m43gDMFopPumaZ3YuriloxmPPERbt21p8fplU9Bfz+WXSSsWIo Received-SPF: pass client-ip=212.227.15.18; envelope-from=michael.albinus@gmx.de; helo=mout.gmx.net X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.help:147964 Archived-At: Robert Pluim writes: Hi Robert, >>>>>> On Thu, 12 Sep 2024 16:47:39 +0200, Michael Albinus said: > > Michael> Visuwesh writes: > >> Hello all, > > Michael> Hi Visuwesh, > > >> I know that non-essential=3Dt prevents Tramp from establishing new > >> connections but is there a way to make Tramp use a very short time= out > >> when trying to connect to a previously established connection that= is > >> now unreachable? What I mean is: if I am connected to a remote ho= st 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 `t= ramp-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=CA=BCt tell =E2=98=BA=EF=B8=8F) Yes, even the Tramp manual speaks about: --8<---------------cut here---------------start------------->8--- 4.19.2 Detection of session hangouts ------------------------------------ =E2=80=98ssh=E2=80=99 sessions on the local host hang when the network is d= own. TRAMP cannot safely detect such hangs. OpenSSH can be configured to kill such hangs with the following settings in =E2=80=98~/.ssh/config=E2=80=99: Host * ServerAliveInterval 5 ServerAliveCountMax 2 --8<---------------cut here---------------end--------------->8--- But who reads manuals ... > Robert Best regards, Michael.