Help with ssh -A, screen, ssh -a, detach, logout

raf ssh at raf.org
Sat Jun 6 14:49:57 AEST 2020


Peter Stuge wrote:

> Hi,
> 
> raf wrote:
> > If I ssh-with-agent-forwarding from one host to a
> > second host, and on the second host use something like
> > nohup/screen/tmux/daemon, and from within that new
> > process session, start a long-running command via
> > ssh-without-agent-forwarding on a third host, I would
> > expect to be able to (e.g.) detach from the screen
> > session and log out of the second host,
> 
> I do this every now and then and for me it works exactly as expected.
> 
> I don't see the behavior you describe.
> 
> >   host1 ssh: OpenSSH_8.1p1, OpenSSL 1.1.1g  21 Apr 2020
> >   host2 ssh: OpenSSH_7.4p1 Debian-10+deb9u7, OpenSSL 1.0.2u  20 Dec 2019
> >   host3 ssh: OpenSSH_7.4p1 Debian-10+deb9u7, OpenSSL 1.0.2u  20 Dec 2019
> 
> I never use debian, only systems with upstream OpenSSH-portable.
> 
> So I'd suggest to try to reproduce with a host2 (and possibly also host3)
> that runs vanilla OpenSSH-portable, without distribution patches.
> 
> You could even use host1 as host2 and host3 for testing.
> 
> Kind regards
> 
> //Peter

Hi Peter,

Thanks for that. By using openssh-portable as sshd on
host2, the problem disappears completely.
Unsurprisingly, lsof shows sshd having no second
connection to the agent socket after starting the
second ssh from host2 to host3.

So it looks like something that the debian folks have
changed. I'll try to find out what, or maybe just
report it as a bug in the debian package and hope
they fix it.

Thanks again.

cheers,
raf



More information about the openssh-unix-dev mailing list