[SATLUG] /tmp setting

Tweeks tweeksjunk2 at theweeks.org
Mon Jun 15 23:48:45 CDT 2009


On Monday 15 June 2009 08:18:55 pm Andrew Pickens wrote:
> Geoff wrote:
> > Brad Knowles wrote:
> >> Geoff wrote:
> >>> I've never used the -d option in ls much.  I can see where it's pretty
> >>> handy.  I'll be using it from now on.
> >>
> >> Note that the -d option is to list the ownership and permissions of
> >> the directory itself, as opposed to the contents of the directory.
> >>
> >> If that's not what you intended, then you should go do some testing to
> >> make sure you know how it operates -- it won't do anything for you if
> >> it's not used on a directory.
> >
> > zactly.  there's a huge difference in /tmp/ and /tmp
>
> Problem fixed with: $ sudo chmod 1777 /tmp
>
> Thank you all.  Now I'll try to understand what I did.

Hehe.. Well, you probably already know that "777" = rwx rwx rwx for the owner, 
group and other.  Well the preceeding "1" merely sets the "sticky bit" 
(the "t" in "wrxwrxwrt").  The sticky bit (on modern Linux systems) just 
keeps OTHER people from deleting your files within a directory that everyone 
own has write permissions in (in a nut shell).  Useful for a shared group dir 
like /tmp/ where your account's active session temp files are stored.. but 
where you don't want other processess nuking your stuff.
That's all it is.

Problem now is (inUbuntu) fidinf out who or what changed your /tmp/ 
permissions.
Tweeks


More information about the SATLUG mailing list