[openbox] openbox connected to remote display doesn't know X server gone

Xavier Toth txtoth at gmail.com
Mon Sep 28 09:11:09 EDT 2009


On Sun, Sep 27, 2009 at 8:19 PM, Anthony Thyssen
<A.Thyssen at griffith.edu.au> wrote:
> On Fri, 25 Sep 2009 08:51:52 -0500
> Xavier Toth <txtoth at gmail.com> wrote:
>
> | On Thu, Sep 24, 2009 at 9:47 AM, txtoth <txtoth at gmail.com> wrote:
> | > On Thu, Sep 24, 2009 at 1:57 AM, Anthony Thyssen
> | > <A.Thyssen at griffith.edu.au> wrote:
> | >> On Wed, 23 Sep 2009 16:13:10 -0500
> | >> Xavier Toth <txtoth at gmail.com> wrote:
> | >>
> | >> | I'm running an X server for remote display purposes (some might call
> | >> | it an X terminal). The X client starts an openbox session when a user
> | >> | logs in. If I power off the X server box (something that shouldn't
> | >> | happen but can) when a user is logged in and then do a ps on the X
> | >> | client I see that openbox and a number of other processes started by
> | >> | the openbox session continue to run indefinitely. It appears that
> | >> | openbox doesn't know that it's X connection has been lost. Is there
> | >> | anything that can be done to cleanup these dead sessions?
> | >> |
> | >> Many internet connections don't die when the remote server dies.
> | >> Basically it cant't tell if the host has disappeared, or is just
> | >> not talking.
> | >>
> | >> When the host comes back online usally such connections get a error
> | >> about no such connection from the rebooted host, and the clients
> | >> die.  But only when the host comes back.
> | >>
> | >> This is especially the case with X window UDP packets.
> | >>
> | >> The other solution is that the socket connection be setup with a
> | >> 'keepalive' flag.  This checks the connection for response, and
> | >> closed dead connections when the remote client 'dissapears'.
> | >>
> | >> X windows via SSH tunneling encryption is the standard way X window
> | >> connections are handled these days.   And SSH has options to use
> | >> 'keepalive' socket techniques.
> | >>
> | >> In the system ssh_config or your personal $HOME/.ssh/config
> | >> add the following...
> | >>
> | >> ----------8<--------------
> | >> Host *
> | >>  TCPKeepAlive yes
> | >>  ServerAliveInterval 1800
> | >> ----------8<--------------
> | >>
> | >> the second item is not really needed, but sends an "I'm here"
> | >> type packet every 5 mins to prevent some firewalls and routers
> | >> from killing 'unused connections'.  that takes care of the opposite
> | >> problems.   connections dying when you aren't using them even though
> | >> nothing is wrong at either end.
> | >>
> | >> Both flags are worth it.
> | >>
> | >> PS: to ensure X windows is passed with SSH by default also include a
> | >>   ForwardX11 yes
> | >> in the above.
> | >>
> | >>
> | >>  Anthony Thyssen ( System Programmer )    <A.Thyssen at griffith.edu.au>
> | >>  -----------------------------------------------------------------------------
> | >>            Graffito in a MIT lavatory...
> | >>                   Heisenberg might have been here
> | >>  -----------------------------------------------------------------------------
> | >>     Anthony's Home is his Castle     http://www.cit.gu.edu.au/~anthony/
> | >> _______________________________________________
> | >> openbox mailing list
> | >> openbox at icculus.org
> | >> http://icculus.org/mailman/listinfo/openbox
> | >>
> | >
> | > We are using an ipsec.The X library is supposedly setting SO_KEEPALIVE
> | > on connections it creates so I'll try setting
> | > /proc/sys/net/ipv4/tcp_keepalive_time and see if that helps. Thanks
> | >
> | > Ted
> | >
> |
> | I set the time in  /proc/sys/net/ipv4/tcp_keepalive_time to 1800 but
> | still openbox never realizes that the X server it was connected to is
> | no longer running. This causes a real problem because besides openbox
> | there are a number of its children and eventually you can have a box
> | running with a number of zombies, not good in a production
> | environment.
> |
> have you tried the connections via SSH?
>
>
>
>  Anthony Thyssen ( System Programmer )    <A.Thyssen at griffith.edu.au>
>  -----------------------------------------------------------------------------
>    Two hydrogen atoms walk into a bar.
>    One says, "I've lost my electron".
>    The other says, "Are you sure?"
>    The first replies, "Yes, I'm positive..."
>  -----------------------------------------------------------------------------
>     Anthony's Home is his Castle     http://www.cit.gu.edu.au/~anthony/
> _______________________________________________
> openbox mailing list
> openbox at icculus.org
> http://icculus.org/mailman/listinfo/openbox
>

This is not a option. I must come up with a solution for the existing
configuration.

Ted


More information about the openbox mailing list