Como Utilizar Chmod Unix
The chmod Command
You may have noticed that when you look at a listing of the files in your UNIX account (using the command ls −la),several strange characters appear on the left side of the screen. For example:
% ls −la
total 424
drwx−−x−−x
dr−xr−xr−x
−rw−−−−−−−
−rw−−−−−−−
−rw−−−−−−−
drwx−−−−−−
drwx−−−−−−
drwxr−xr−x
243
1
1
1
1
2
13
bm901
root
bm901
bm901
bm901
bm901
bm901
bm901
student
root
student
student
student
student
student
student
1024
3
2504
2140
785
512
512
1024
MayMay
Apr
Feb
May
May
May
May
15
14
02
18
07
14
15
15
14:03
14:19
15:52
20:07
12:22
16:28
13:50
14:37
./
../
.Mailbox
.Xauthority
.cshrc
.mozilla/
Mail/public_html/
These series of dashes and letters indicate what the file access permissions of each file are. Or, in other words, who
can do what to these files.
Each file or directory is allotted 10characters to indicate file access permissions. The first character indicates
whether it is a file or a directory. If the first character is a "d", then it is a directory. A "−" indicates that it is a file.The next 3 characters (2−4) indicate which permissions the owner of the file has. The owner is the user who created
the file. Note that bm901 is the owner of the files in the example above. The nextset of characters (5−7) indicates
permissions for the group. The group is a set of users categorized together according to what permissions they have.
In the example above, the user bm901 is in thegroup "student", The last set of characters (8−10) indicates
permissions for all others, meaning everyone else in the world.
Access permissions are categorized mainly into 3 functions: Read, Write,and eXecute. An "r" indicates read
permissions for a file or directory. A "w" indicates write permissions. An "x" indicates execution permissions if it is
a file, and search permissions if it is...
Regístrate para leer el documento completo.