home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / unix / xenix / sco / 2577 < prev    next >
Encoding:
Text File  |  1992-07-26  |  1.6 KB  |  37 lines

  1. Newsgroups: comp.unix.xenix.sco
  2. Path: sparky!uunet!europa.asd.contel.com!darwin.sura.net!mips!zaphod.mps.ohio-state.edu!cs.utexas.edu!chinacat!chip
  3. From: chip@chinacat.unicom.com (Chip Rosenthal)
  4. Subject: Re: Shutdown does not prevent logins
  5. Organization: Unicom Systems Development, Austin, TX
  6. Date: Sun, 26 Jul 1992 19:33:46 GMT
  7. Message-ID: <1992Jul26.193346.328@chinacat.unicom.com>
  8. References: <4474@teslab.lab.oz.au>
  9. Lines: 26
  10.  
  11. In article <4474@teslab.lab.oz.au>
  12.     andrew@teslab.lab.oz.au (Andrew Phillips) writes:
  13. >We recently upgraded to Xenix 2.3.4.  Now shutdown does not stop
  14. >users logging in once it is run.  This means that if someone logs in
  15. >in the minute before the system is shutdown they will have no warning.
  16.  
  17. I don't know that this was ever the case.  I'm not saying that it
  18. isn't, just that I don't recall what the old behaviour was.
  19.  
  20. /etc/shutdown has not changed in ages.  Starting at two minutes before
  21. the shutdown, /etc/shutdown does a `kill -3 1'.  This tells `init' to
  22. stop spawning gettys on terminal lines.  It does not, however, kill
  23. off any gettys already sitting there with a `login:' prompt.
  24.  
  25. If you want to kill off those gettys, you could modify /etc/shutdown
  26. to do something like:
  27.  
  28.     pids=`ps -ef | awk '$1 == "root" && $8 == "-" && $9 ~ /^tty/ {print $2}'`
  29.     [ "$pids" ] && kill $pids
  30.  
  31. right after the `kill -3 1'.
  32.  
  33. -- 
  34. Chip Rosenthal  512-482-8260 | Let the wayward children play.  Let the wicked
  35. Unicom Systems Development   | have their day.  Let the chips fall where they
  36. <chip@chinacat.Unicom.COM>   | may.  I'm going to Disneyland.  -Timbuk 3
  37.