Re: [Libvir] PATCH: Prevent zombie ssh tunnels

2007-09-17 Thread Daniel Veillard
On Fri, Sep 14, 2007 at 03:14:02AM +0100, Daniel P. Berrange wrote: On Tue, Sep 11, 2007 at 04:56:13AM -0400, Daniel Veillard wrote: On Tue, Sep 11, 2007 at 12:59:59AM +0100, Daniel P. Berrange wrote: I noticed that when using the SSH tunnel for the remote driver I ended up with alot of

Re: [Libvir] PATCH: Prevent zombie ssh tunnels

2007-09-14 Thread Richard W.M. Jones
Daniel P. Berrange wrote: On Tue, Sep 11, 2007 at 04:56:13AM -0400, Daniel Veillard wrote: On Tue, Sep 11, 2007 at 12:59:59AM +0100, Daniel P. Berrange wrote: I noticed that when using the SSH tunnel for the remote driver I ended up with alot of zombie SSH processes. We simply forgot to

Re: [Libvir] PATCH: Prevent zombie ssh tunnels

2007-09-13 Thread Daniel P. Berrange
On Tue, Sep 11, 2007 at 04:56:13AM -0400, Daniel Veillard wrote: On Tue, Sep 11, 2007 at 12:59:59AM +0100, Daniel P. Berrange wrote: I noticed that when using the SSH tunnel for the remote driver I ended up with alot of zombie SSH processes. We simply forgot to waitpid() on the child when a

Re: [Libvir] PATCH: Prevent zombie ssh tunnels

2007-09-11 Thread Richard W.M. Jones
Daniel P. Berrange wrote: I noticed that when using the SSH tunnel for the remote driver I ended up with alot of zombie SSH processes. We simply forgot to waitpid() on the child when a connection attempt failed, or when shutting down an open remote connection. Attached is a possible patch This

Re: [Libvir] PATCH: Prevent zombie ssh tunnels

2007-09-11 Thread Daniel Veillard
On Tue, Sep 11, 2007 at 12:59:59AM +0100, Daniel P. Berrange wrote: I noticed that when using the SSH tunnel for the remote driver I ended up with alot of zombie SSH processes. We simply forgot to waitpid() on the child when a connection attempt failed, or when shutting down an open remote

Re: [Libvir] PATCH: Prevent zombie ssh tunnels

2007-09-11 Thread Gerd Hoffmann
Daniel Veillard wrote: - the ssh process dies - libvirt based application takes some time to notice it - the OS span a new process with the same PID after a PID rollabck Can not happen as long as libvirt hasn't asked for the exist status via waitpid() because the pid is still in use

Re: [Libvir] PATCH: Prevent zombie ssh tunnels

2007-09-11 Thread Daniel Veillard
On Tue, Sep 11, 2007 at 11:35:46AM +0200, Gerd Hoffmann wrote: Daniel Veillard wrote: - the ssh process dies - libvirt based application takes some time to notice it - the OS span a new process with the same PID after a PID rollabck Can not happen as long as libvirt hasn't asked

Re: [Libvir] PATCH: Prevent zombie ssh tunnels

2007-09-11 Thread Richard W.M. Jones
Daniel Veillard wrote: On Tue, Sep 11, 2007 at 11:35:46AM +0200, Gerd Hoffmann wrote: Daniel Veillard wrote: - the ssh process dies - libvirt based application takes some time to notice it - the OS span a new process with the same PID after a PID rollabck Can not happen as long as

Re: [Libvir] PATCH: Prevent zombie ssh tunnels

2007-09-11 Thread Gerd Hoffmann
Daniel Veillard wrote: On Tue, Sep 11, 2007 at 11:35:46AM +0200, Gerd Hoffmann wrote: Daniel Veillard wrote: - the ssh process dies - libvirt based application takes some time to notice it - the OS span a new process with the same PID after a PID rollabck Can not happen as long as

[Libvir] PATCH: Prevent zombie ssh tunnels

2007-09-10 Thread Daniel P. Berrange
I noticed that when using the SSH tunnel for the remote driver I ended up with alot of zombie SSH processes. We simply forgot to waitpid() on the child when a connection attempt failed, or when shutting down an open remote connection. Attached is a possible patch Dan. -- |=- Red Hat,