home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / sys / next / sysadmin / 7232 < prev    next >
Encoding:
Internet Message Format  |  1992-12-28  |  2.0 KB

  1. Path: sparky!uunet!stanford.edu!morrow.stanford.edu!morrow.stanford.edu!usenet
  2. From: lane@sumex-aim.stanford.edu (Christopher Lane)
  3. Newsgroups: comp.sys.next.sysadmin
  4. Subject: The story with MOTD.
  5. Date: 28 Dec 1992 17:48:31 GMT
  6. Organization: Stanford University
  7. Lines: 27
  8. Message-ID: <1hnelfINN7kp@morrow.stanford.edu>
  9. Reply-To: lane@sumex-aim.stanford.edu (Christopher Lane)
  10. NNTP-Posting-Host: ssrg-next-1.stanford.edu
  11.  
  12. As a couple of earlier threads discussed, MOTD for 2.X doesn't work under 3.0.
  13.  
  14. Under 3.0, the 'loginwindow' application takes care of updating the 'wtmp' and  
  15. 'lastlog' files so this feature of MOTD became redundant.  However, the bug  
  16. that kept it from working is that the 'loginwindow' application updates the  
  17. 'wtmp' file BEFORE running the LoginHook, which makes it that much harder for  
  18. MOTD to figure out if you've seen the current motd file since your last login.
  19.  
  20. (I'm not sure if the 'loginwindow' should update the wtmp before or after the  
  21. LoginHook since the LoginHook does have the option of rejecting the user.)
  22.  
  23. I've patched MOTD so that it ignores the first 'wtmp' record that matches what  
  24. it's looking for and goes on.  This seems to work and I've had a number of  
  25. people try it out who also feel it's working now.  I've also removed the code  
  26. that is now redundant with 'loginwindow', including the entire LogoutHook.
  27.  
  28. As before, if you want MOTD to show the motd file, regardless of whether it  
  29. believes the user has seen it, you can set the boolean default OnlyOnce to 'No'  
  30. to get that behavior -- the code patch that's been going around isn't needed.
  31.  
  32. I've ftp'd the patched MOTD to the submissions directories of the CS.ORST.EDU  
  33. and SONATA.CC.PURDUE.EDU NeXT archives -- though you might want to wait until  
  34. it migrates to the real directories.  There is already a non-patched 3.0 copy  
  35. of MOTD on at least one of archives.  To check if you have what is supposed to  
  36. be a working version, 'grep Kludge MOTD_main.m' should return a match..
  37.  
  38. - Christopher
  39.