| 25 Permissions and Ownership




Download 4,86 Mb.
Pdf ko'rish
bet14/18
Sana23.12.2023
Hajmi4,86 Mb.
#127288
1   ...   10   11   12   13   14   15   16   17   18
Bog'liq
introductiontolinux

25
Permissions and Ownership
WARNING: Please read through this entire section BEFORE attempting it. Altering the permissions 
of the contents of your home directory could remove access for yourself, meaning that a Systems 
Administrator has to come along and fix them.
Permissions in Microsoft Windows are a little easier to understand and configure than those in Linux. 
In Windows, you simply right click on a file or folder and specify the username and what permissions 
you would like for it. The bonus with this is that you can have as many different permissions for as 
many different groups or individual users that you want (this is achievable in Linux through the use 
of ACL’s, although this is much more advanced)
In Linux, things are generally a little more restrictive. A file or folder only has three user categories: 
User, Group, Other. Each user category can only have three sorts of permission applied to it. Read, 
Write, Execute. You can see some existing permissions by running the following commands:
Once you run this command you should see something like the following:
This might initially look confusing, so let’s break this down...
cd ~
man -k directory
ls -la
Change your working directory to 
your home directory.
Print the current working directory - 
You should be in /home/msai135 (where 
msai135 is your own username)
Runs the ‘List directory contents’ 
command with the arguments ‘long list 
format’ (l) and ‘all’ (a).


26
 |


27
Setting Permissions
Permissions can be set on a file or folder using two simple methods. The two methods available are 
The Binary Method, and The Symbolic Method. Choose the one that is easiest for you.

Download 4,86 Mb.
1   ...   10   11   12   13   14   15   16   17   18




Download 4,86 Mb.
Pdf ko'rish