home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #27 / NN_1992_27.iso / spool / comp / windows / x / 19273 < prev    next >
Encoding:
Internet Message Format  |  1992-11-17  |  2.0 KB

  1. Path: sparky!uunet!charon.amdahl.com!pacbell.com!ames!olivea!charnel!sifon!thunder.mcrcim.mcgill.edu!mouse
  2. From: mouse@thunder.mcrcim.mcgill.edu (der Mouse)
  3. Newsgroups: comp.windows.x
  4. Subject: Re: xterm phantoms
  5. Message-ID: <1992Nov18.070243.103@thunder.mcrcim.mcgill.edu>
  6. Date: 18 Nov 92 07:02:43 GMT
  7. References: <1eb92mINNdan@life.ai.mit.edu>
  8. Organization: McGill Research Centre for Intelligent Machines
  9. Lines: 41
  10.  
  11. In article <1eb92mINNdan@life.ai.mit.edu>, bruce@maypo.ai.mit.edu (Bruce Walton) writes:
  12.  
  13. > Often some of our users run X clients on remote sparcstations, and
  14. > terminate their local X server without shutting it down properly.
  15.  
  16. When this happens, the operating system is supposed to shut down the
  17. network connections when the server process dies.
  18.  
  19. > This happens most often to owners of PC's who run X servers (like
  20. > MacX or whatever).
  21.  
  22. Ah, where there isn't any operating system to do the automatic shutdown
  23. stuff, or when the machine is shut down uncleanly.
  24.  
  25. One way would be to build a special version of xterm that turns on
  26. network-layer keepalives.  Another would be to just shrug your
  27. shoulders and say "sorry, you crash your X server by turning off your
  28. bitty box, you get ghost logins".
  29.  
  30. > Does anyone know how to recognize these inactive X clients (xterms),
  31.  
  32. Any utmp entries idle for more than 12 hours are good canididates. :)
  33.  
  34. > and clear out their utmp entries (without rebooting)?
  35.  
  36. Make the xterm go away.  One of the simplest ways to do this is to make
  37. the xterm try to do something with the X server.  If the machine is up,
  38. it'll die right away with ECONNRESET; if not, it'll die a few minutes
  39. later with ETIMEDOUT.  Either way, it'll go away, and if it's
  40. non-buggy, erase the utmp entry first.
  41.  
  42. As for how to do this, you could just write a character to the relevant
  43. pty.  If it's not a ghost, the character will appear inexplicably in
  44. the window, but I don't see any good way around that, unless you can
  45. think of something else you could send that'll force xterm to try to do
  46. something with the X server.
  47.  
  48.                     der Mouse
  49.  
  50.                 mouse@larry.mcrcim.mcgill.edu
  51.