Gnus development mailing list
 help / color / mirror / Atom feed
* Gnus refuses to connect after suspend and resume in different network, but Gnus in fresh emacs works
@ 2023-01-06 14:22 Steinar Bang
  2023-01-12  8:50 ` Alberto Luaces
  0 siblings, 1 reply; 11+ messages in thread
From: Steinar Bang @ 2023-01-06 14:22 UTC (permalink / raw)
  To: ding

Platform: amd64, debian 11.6 "bullseye"
          GNU Emacs 27.1,
          Gnus v5.13 (native gnus of emas 27.1)

I started the emacs process at home and ran Gnus it in for several days.

Yesterday I unplugged gnus at home, and suspended the laptop.

Today I resumed the laptop in a different LAN and tried to plug in the
unplugged gnus.

But gnus was unable to connect.

So I stopped gnus and started gnus in the old emacs process, but gnus
was still unable to connect.

But gnus started from a fresh emacs process worked fine.

Is there a way to figure out what's gone wrong with the old emacs
process?  I suspect a cached DNS server?  Is there a way to find out if
that is the case?

Has anyone else observed this behaviour?

Does anyone know how to fix this (other than starting a new emacs)?

Thanks!



^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Gnus refuses to connect after suspend and resume in different network, but Gnus in fresh emacs works
  2023-01-06 14:22 Gnus refuses to connect after suspend and resume in different network, but Gnus in fresh emacs works Steinar Bang
@ 2023-01-12  8:50 ` Alberto Luaces
  2023-01-12 21:42   ` Eric Abrahamsen
  2023-01-30 19:31   ` Steinar Bang
  0 siblings, 2 replies; 11+ messages in thread
From: Alberto Luaces @ 2023-01-12  8:50 UTC (permalink / raw)
  To: ding

Steinar Bang <sb@dod.no> writes:

> Has anyone else observed this behaviour?

I think many.

> Does anyone know how to fix this (other than starting a new emacs)?

You can start by closing all opened but stale server connections with
"C" in the server buffer, and then reconnecting to everything (it
implies reopening connections) with "g" in the group buffer.

Some time ago I read that someone got this automated by catching the
suspend dbus event and closing the connections either on suspending or
resuming.

-- 
Alberto



^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Gnus refuses to connect after suspend and resume in different network, but Gnus in fresh emacs works
  2023-01-12  8:50 ` Alberto Luaces
@ 2023-01-12 21:42   ` Eric Abrahamsen
  2023-01-13  7:55     ` Robert Pluim
                       ` (3 more replies)
  2023-01-30 19:31   ` Steinar Bang
  1 sibling, 4 replies; 11+ messages in thread
From: Eric Abrahamsen @ 2023-01-12 21:42 UTC (permalink / raw)
  To: ding

Alberto Luaces <aluaces@udc.es> writes:

> Steinar Bang <sb@dod.no> writes:
>
>> Has anyone else observed this behaviour?
>
> I think many.
>
>> Does anyone know how to fix this (other than starting a new emacs)?
>
> You can start by closing all opened but stale server connections with
> "C" in the server buffer, and then reconnecting to everything (it
> implies reopening connections) with "g" in the group buffer.
>
> Some time ago I read that someone got this automated by catching the
> suspend dbus event and closing the connections either on suspending or
> resuming.

I was going to say that I thought someone had added an option for
closing Gnus servers when a laptop sleeps -- I looked at the library and
it was me :(

See if you've got a `gnus-dbus-close-on-sleep' option, and if so, try
setting it to t.



^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Gnus refuses to connect after suspend and resume in different network, but Gnus in fresh emacs works
  2023-01-12 21:42   ` Eric Abrahamsen
@ 2023-01-13  7:55     ` Robert Pluim
  2023-01-13  9:47     ` Alberto Luaces
                       ` (2 subsequent siblings)
  3 siblings, 0 replies; 11+ messages in thread
From: Robert Pluim @ 2023-01-13  7:55 UTC (permalink / raw)
  To: Eric Abrahamsen; +Cc: ding

>>>>> On Thu, 12 Jan 2023 13:42:47 -0800, Eric Abrahamsen <eric@ericabrahamsen.net> said:
    Eric> I was going to say that I thought someone had added an option for
    Eric> closing Gnus servers when a laptop sleeps -- I looked at the library and
    Eric> it was me :(

    Eric> See if you've got a `gnus-dbus-close-on-sleep' option, and if so, try
    Eric> setting it to t.

Thereʼs also a patch floating around (on emacs-devel?) which
re-initializes glibcʼs DNS routines which might help.

Robert
-- 


^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Gnus refuses to connect after suspend and resume in different network, but Gnus in fresh emacs works
  2023-01-12 21:42   ` Eric Abrahamsen
  2023-01-13  7:55     ` Robert Pluim
@ 2023-01-13  9:47     ` Alberto Luaces
  2023-01-13 17:49       ` Eric Abrahamsen
  2023-01-30 19:40     ` Steinar Bang
  2023-08-11 20:31     ` John Haman
  3 siblings, 1 reply; 11+ messages in thread
From: Alberto Luaces @ 2023-01-13  9:47 UTC (permalink / raw)
  To: ding

Eric Abrahamsen <eric@ericabrahamsen.net> writes:

> I was going to say that I thought someone had added an option for
> closing Gnus servers when a laptop sleeps -- I looked at the library and
> it was me :(

Wonderful!  I didn't know that it was already there!

-- 
Alberto



^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Gnus refuses to connect after suspend and resume in different network, but Gnus in fresh emacs works
  2023-01-13  9:47     ` Alberto Luaces
@ 2023-01-13 17:49       ` Eric Abrahamsen
  0 siblings, 0 replies; 11+ messages in thread
From: Eric Abrahamsen @ 2023-01-13 17:49 UTC (permalink / raw)
  To: ding

Alberto Luaces <aluaces@udc.es> writes:

> Eric Abrahamsen <eric@ericabrahamsen.net> writes:
>
>> I was going to say that I thought someone had added an option for
>> closing Gnus servers when a laptop sleeps -- I looked at the library and
>> it was me :(
>
> Wonderful!  I didn't know that it was already there!

Apparently I didn't either, ha.



^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Gnus refuses to connect after suspend and resume in different network, but Gnus in fresh emacs works
  2023-01-12  8:50 ` Alberto Luaces
  2023-01-12 21:42   ` Eric Abrahamsen
@ 2023-01-30 19:31   ` Steinar Bang
  1 sibling, 0 replies; 11+ messages in thread
From: Steinar Bang @ 2023-01-30 19:31 UTC (permalink / raw)
  To: ding

>>>>> Alberto Luaces <aluaces@udc.es>:

>> Does anyone know how to fix this (other than starting a new emacs)?

> You can start by closing all opened but stale server connections with
> "C" in the server buffer, and then reconnecting to everything (it
> implies reopening connections) with "g" in the group buffer.

Thanks! I will save this somewhere and try it next time this occurs.

> Some time ago I read that someone got this automated by catching the
> suspend dbus event and closing the connections either on suspending or
> resuming.

Oh, that would be nice!



^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Gnus refuses to connect after suspend and resume in different network, but Gnus in fresh emacs works
  2023-01-12 21:42   ` Eric Abrahamsen
  2023-01-13  7:55     ` Robert Pluim
  2023-01-13  9:47     ` Alberto Luaces
@ 2023-01-30 19:40     ` Steinar Bang
  2023-01-30 20:48       ` Eric Abrahamsen
  2023-08-11 20:31     ` John Haman
  3 siblings, 1 reply; 11+ messages in thread
From: Steinar Bang @ 2023-01-30 19:40 UTC (permalink / raw)
  To: ding

>>>>> Eric Abrahamsen <eric@ericabrahamsen.net>:

> I was going to say that I thought someone had added an option for
> closing Gnus servers when a laptop sleeps -- I looked at the library
> and it was me :(

:-)

> See if you've got a `gnus-dbus-close-on-sleep' option, and if so, try
> setting it to t.

Hm... I don't have an emacs variable named gnus-dbus-close-on-sleep

gnus-version: Gnus v5.13
emacs-version: GNU Emacs 27.1 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.24, cairo version 1.16.0) of 2023-01-06, modified by Debian

locate-library says that gnus comes from: ~/git/emacs/lisp/gnus/gnus.elc

The branch of the ~/git/emacs/ repo is called emacs-27-with-gnus-cloud-from-emacs-28

So without checking closer and vaguely remembering setting it up, I'm
guessing that's what it is: it is the gnus that's in emacs-27 but with
the gnus-cloud.el file fetched from emacs-28, because the gnus-cloud in
emacs-27 doesn't work.



^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Gnus refuses to connect after suspend and resume in different network, but Gnus in fresh emacs works
  2023-01-30 19:40     ` Steinar Bang
@ 2023-01-30 20:48       ` Eric Abrahamsen
  0 siblings, 0 replies; 11+ messages in thread
From: Eric Abrahamsen @ 2023-01-30 20:48 UTC (permalink / raw)
  To: ding

Steinar Bang <sb@dod.no> writes:

>>>>>> Eric Abrahamsen <eric@ericabrahamsen.net>:
>
>> I was going to say that I thought someone had added an option for
>> closing Gnus servers when a laptop sleeps -- I looked at the library
>> and it was me :(
>
> :-)
>
>> See if you've got a `gnus-dbus-close-on-sleep' option, and if so, try
>> setting it to t.
>
> Hm... I don't have an emacs variable named gnus-dbus-close-on-sleep
>
> gnus-version: Gnus v5.13
> emacs-version: GNU Emacs 27.1 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.24, cairo version 1.16.0) of 2023-01-06, modified by Debian
>
> locate-library says that gnus comes from: ~/git/emacs/lisp/gnus/gnus.elc
>
> The branch of the ~/git/emacs/ repo is called emacs-27-with-gnus-cloud-from-emacs-28
>
> So without checking closer and vaguely remembering setting it up, I'm
> guessing that's what it is: it is the gnus that's in emacs-27 but with
> the gnus-cloud.el file fetched from emacs-28, because the gnus-cloud in
> emacs-27 doesn't work.

Might be time to start running master! There's a lot of good stuff in
upcoming 29.



^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Gnus refuses to connect after suspend and resume in different network, but Gnus in fresh emacs works
  2023-01-12 21:42   ` Eric Abrahamsen
                       ` (2 preceding siblings ...)
  2023-01-30 19:40     ` Steinar Bang
@ 2023-08-11 20:31     ` John Haman
  2023-08-11 21:26       ` John Haman
  3 siblings, 1 reply; 11+ messages in thread
From: John Haman @ 2023-08-11 20:31 UTC (permalink / raw)
  To: ding

Eric Abrahamsen <eric@ericabrahamsen.net> writes:

> Alberto Luaces <aluaces@udc.es> writes:
>
>> Steinar Bang <sb@dod.no> writes:
>>
>>> Has anyone else observed this behaviour?
>>
>> I think many.
>>
>>> Does anyone know how to fix this (other than starting a new emacs)?
>>
>> You can start by closing all opened but stale server connections with
>> "C" in the server buffer, and then reconnecting to everything (it
>> implies reopening connections) with "g" in the group buffer.
>>
>> Some time ago I read that someone got this automated by catching the
>> suspend dbus event and closing the connections either on suspending or
>> resuming.
>
> I was going to say that I thought someone had added an option for
> closing Gnus servers when a laptop sleeps -- I looked at the library and
> it was me :(
>
> See if you've got a `gnus-dbus-close-on-sleep' option, and if so, try
> setting it to t.
>
>

Is there anything like this for MacOS? Windows?

-- 
Dr. John Haman
Maryland, USA



^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: Gnus refuses to connect after suspend and resume in different network, but Gnus in fresh emacs works
  2023-08-11 20:31     ` John Haman
@ 2023-08-11 21:26       ` John Haman
  0 siblings, 0 replies; 11+ messages in thread
From: John Haman @ 2023-08-11 21:26 UTC (permalink / raw)
  To: ding

John Haman <mail@johnhaman.org> writes:

> Eric Abrahamsen <eric@ericabrahamsen.net> writes:
>
>> Alberto Luaces <aluaces@udc.es> writes:
>>
>>> Steinar Bang <sb@dod.no> writes:
>>>
>>>> Has anyone else observed this behaviour?
>>>
>>> I think many.
>>>
>>>> Does anyone know how to fix this (other than starting a new emacs)?
>>>
>>> You can start by closing all opened but stale server connections with
>>> "C" in the server buffer, and then reconnecting to everything (it
>>> implies reopening connections) with "g" in the group buffer.
>>>
>>> Some time ago I read that someone got this automated by catching the
>>> suspend dbus event and closing the connections either on suspending or
>>> resuming.
>>
>> I was going to say that I thought someone had added an option for
>> closing Gnus servers when a laptop sleeps -- I looked at the library and
>> it was me :(
>>
>> See if you've got a `gnus-dbus-close-on-sleep' option, and if so, try
>> setting it to t.
>>
>>
>
> Is there anything like this for MacOS? Windows?

Actually, just installing dbus from homebrew seems to remediate Gnus's suspend issues on MacOS.


--
Dr. John Haman
Maryland, USA



^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2023-08-11 21:26 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-01-06 14:22 Gnus refuses to connect after suspend and resume in different network, but Gnus in fresh emacs works Steinar Bang
2023-01-12  8:50 ` Alberto Luaces
2023-01-12 21:42   ` Eric Abrahamsen
2023-01-13  7:55     ` Robert Pluim
2023-01-13  9:47     ` Alberto Luaces
2023-01-13 17:49       ` Eric Abrahamsen
2023-01-30 19:40     ` Steinar Bang
2023-01-30 20:48       ` Eric Abrahamsen
2023-08-11 20:31     ` John Haman
2023-08-11 21:26       ` John Haman
2023-01-30 19:31   ` Steinar Bang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).