Updating tutorial chown
This commit is contained in:
parent
3f623da9d2
commit
d2044072d1
|
@ -80,6 +80,23 @@ access the files
|
|||
chmod -R o=wxr,g=xr, o=x buds
|
||||
#+end_src
|
||||
|
||||
This will change the permissions for:
|
||||
|
||||
* The owner (4 = read; 2 = write; 1 = execute)
|
||||
* The group (4 = read) and
|
||||
* Others (4 = read)
|
||||
|
||||
Use ~-R~ if you want to apply recursive ~chmod~
|
||||
|
||||
#+begin_src bash
|
||||
chmod 744 NameOfFileHere
|
||||
#+end_src
|
||||
|
||||
Think of the following code: what does that code do?
|
||||
|
||||
#+begin_src bash
|
||||
chmod -R 755 NameOfFileHere
|
||||
#+end_src
|
||||
|
||||
*** The output now is:
|
||||
|
||||
|
@ -96,9 +113,15 @@ Remember how it looks before
|
|||
But I still can open the files. That is because need to change the owner:
|
||||
|
||||
#+begin_example bash
|
||||
chown -R 755 buds # Try this and check the result
|
||||
chown -R user buds # Then try this and check the result
|
||||
chown NameOfownerHere buds # Try this and check the result
|
||||
#+end_example
|
||||
|
||||
Include the owner then ~:~ and then the name of the group to change ownership for each one of those users
|
||||
|
||||
#+begin_example bash
|
||||
chown user:usergroup buds # Then try this and check the result
|
||||
#+end_example
|
||||
|
||||
|
||||
ps: should use`sudo` to run this command, so be careful and make a scratch directory
|
||||
to run tests.
|
||||
|
|
Loading…
Reference in New Issue