Re: [ILUG] ssh leaves sessions lying around

From: Niall O Broin (niall at domain linux.ie)
Date: Tue 17 Sep 2002 - 13:13:07 IST


On Tue, Sep 17, 2002 at 11:52:24AM +0100, Ronan Waide wrote:

> On September 15, conor.daly at domain oceanfree.net said:
> > Irritating little something here. I kinda think I saw it mentioned before
> > but I'm not sure. Anyhow, using Openssh 2.9p2 (yeah, I know I need to
> > upgrade...), in X, I ssh to a remote machine, launch OpenOffice.org, do my
> > stuff and exit. The ssh session however, persists. It seems to
>
> This /usually/ happens when you've started a background process on the
> ssh connection. You can use one of ssh's tilde-escapes to either
> background the ssh connection or kill it off.

It's in the archives - answer in the OpenSSH FAQ at
http://www.openssh.org/faq.html#3.10 I'm on the ball with this because I
just looked it up myself, having encountered a similar problem when I wanted
to leave a big rsync running in the background. However, the answer did work
for me.

I did

shopt -s huponexit

followed by

nohup rsync options &

and the rsync was working away. I then exited the remote shell, and the ssh
session ended correctly. However, despite the nohup the rsync was killed.

Niall



This archive was generated by hypermail 2.1.6 : Thu 06 Feb 2003 - 13:18:54 GMT