What do you mean? Is the file owner attempting the changes? 
A user cannot chmod root's files  :-)
----- Forwarded message from Richard Spencer <[EMAIL PROTECTED]> -----

> To: Erik Jakobsen <[EMAIL PROTECTED]>
> From: Richard Spencer <[EMAIL PROTECTED]>
> Subject: Re: Chmod.
> 
> In the following example:
> -rw-rw-r--   1 rks      rks         28422 Jun 15 18:05 smog
> 
> 
> -rw-rw-r--   1 rks      rks         28422 Jun 15 18:05 smog
>  ---
>   |
>  these 3 places indicate what the OWNER can do; in this case, read and write
> 
> -rw-rw-r--   1 rks      rks         28422 Jun 15 18:05 smog
>     ---
>      |
>     these 3 indicate what group owners can do; in this case read and write
> 
> -rw-rw-r--   1 rks      rks         28422 Jun 15 18:05 smog
>        ---
>         |
>        and these indicate what ordinary users can do; in this case read only.
> 
> 
> Just remember two things: 
> 
>   4=read, 2=write and 1=execute   and
>   
>   three numbers (664, for example) represent owner, group and user permissions; 
>   digit 1 for owner permissions, 2 for group, and 3 for ordinary user permissions.
> 
> You can see that 664 would indicate
> 
> (421421421)
> 
> -rw-rw-r--   1 rks      rks         28422 Jun 15 18:05 smog
>  |||
> 6 for owner (read+write,) 
> 
> -rw-rw-r--   1 rks      rks         28422 Jun 15 18:05 smog
>     |||
> 6 for group (read+write,) 
> 
> -rw-rw-r--   1 rks      rks         28422 Jun 15 18:05 smog
>        |||
> and 4 for ordinary users (read.)
> 
> 
> Now, say I don't want users to be able to read this file. I do:
> 
> $ chmod 660 
> 
> which as you know, means read/write permission for owner and group; no permission  
> for ordinary users.
> 
> This results in:
> 
> -rw-rw----   1 rks      rks         28422 Jun 15 18:05 smog
> 
> So you can see that now, only rks and members of group rks can read and write this 
>file.
> 
> (You could have also used 
> 
> $ chmod u-r 
> 
> to change the permissions.)(o = owner, g = group, u = user; r = read, w = write, x = 
>execute) 
> 
> 
> * Erik Jakobsen <[EMAIL PROTECTED]> [000704 07:28]:
> > Hi folks.
> > 
> > How can I get the different figures for chmod ??.
> > 
> > Or maybe better how do I calculate the figures ??.
> > 
> > Regards Erik.
> > 
> > -- 
> > **************************************
> > *                                    *
> > * Best regards - de bedste hilsener. *
> > *                                    *
> > * Erik Jakobsen - [EMAIL PROTECTED]   *
> > *                                    *
> > **************************************
> > 
> > -
> > To unsubscribe from this list: send the line "unsubscribe linux-newbie" in
> > the body of a message to [EMAIL PROTECTED]
> > Please read the FAQ at http://www.linux-learn.org/faqs
> ---cut here---
> 
> -- 
>  Richard Spencer          "Why Not" is a slogan
> S�o Paulo, Brazil        for an interesting life.
>  [EMAIL PROTECTED]            -- Mason Cooley

----- End forwarded message -----

-- 
  Running Linux 2.2.5, RedHat 6.0
    & the K Desktop Environment
         (windows break)
                                       

-
To unsubscribe from this list: send the line "unsubscribe linux-newbie" in
the body of a message to [EMAIL PROTECTED]
Please read the FAQ at http://www.linux-learn.org/faqs

Reply via email to