home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / unix / question / 9458 < prev    next >
Encoding:
Internet Message Format  |  1992-07-27  |  2.3 KB

  1. Xref: sparky comp.unix.questions:9458 comp.unix.misc:3023
  2. Path: sparky!uunet!gatech!hubcap!ncrcae!ncrlnk!usglnk!usdsd1!dkowalsk
  3. From: dkowalsk@usdsd1.DaytonOH.NCR.COM (Dennis Kowalski)
  4. Newsgroups: comp.unix.questions,comp.unix.misc
  5. Subject: Re: proper mode for /tmp?
  6. Keywords: chmod /tmp
  7. Message-ID: <1526@usdsd1.DaytonOH.NCR.COM>
  8. Date: 27 Jul 92 17:22:18 GMT
  9. References: <1992Jul13.234001.18747@amhux2.am> <1992Jul17.195614.1703@tygra.mich> <1992Jul23.185224.9341@news.uni-stuttgart.de>
  10. Reply-To: dkowalsk@usdsd1.DaytonOH.NCR.COM (Dennis Kowalski)
  11. Organization: NCR USG Data Services Division
  12. Lines: 47
  13.  
  14. In article <1992Jul23.185224.9341@news.uni-stuttgart.de> skok@itwds1.energietechnik.uni-stuttgart.de (Holger Skok) writes:
  15. >
  16. >Hi all you UN*X gurus out there!
  17. >
  18. >I recently deleted my entire /tmp-directory on a SUN IPX. (faulty
  19. >crontab entry). 
  20. >How do I set the the proper mode for that directory? What do the entries 
  21. >in the output of ls -l mean?
  22. >More specifically: what number goes here (v)?
  23. >                    chmod ?777 /tmp
  24. >and what are these:  v     v ?
  25. >                  drwsrwxrwt ... /tmp
  26. >
  27. >Any help appreciated!
  28. >-- 
  29. >*************************************************
  30. >*    Those stupid, horse-brained masses!     *
  31. >*            OPUS (of meadow fame)    *
  32. >*******************************************HSK***
  33.  
  34.  
  35.  
  36.  
  37. I would think that the proper mode would be 1777.
  38.  
  39. The 1xxx format of chmod sets the "sticky bit" in the directory entry.
  40.  
  41. The "sticky bit" will inhibit any user (except root) from deleting any
  42. file that is not owned by that user id.
  43.  
  44. The sticky bit is needed because without it, anyone with write permission
  45. to a directory can delete any file in the directory, even if he/she does not
  46. own the file or even have write permission to it.
  47.  
  48. It is really odd that you can not modify the files owned by someone else,
  49. but you can delete them.
  50.  
  51. That is because by virtue of having write permission at the directory level, 
  52. one is allowed to perform directory level maintenance (i.e. remove unwanted
  53. files).
  54.  
  55. At least that is the way it works on out SVR 5.3 system.
  56.  
  57. -- 
  58. Dennis Kowalski         NCR Corporation  PCD-3                  (513) 445-1843
  59. Systems Architecture    1700 S. Patterson Blvd              VOICEplus 622-1843
  60. USG Data Services Div   Dayton, Ohio     45479 Dennis.Kowalski@DaytonOH.NCR.COM
  61.