Prev | Current Page 218 | Next

Christopher Negus

"Linux Bible, 2008 Edition: Boot up to Ubuntu, Fedora, KNOPPIX, Debian, openSUSE, and 11 Other Distributions"

If a dash appears instead of the
letter, it means that permission is turned off for that associated read, write, or execute.
Because files and directories are different types of elements, read, write, and execute permissions on
files and directories mean different things. Table 2-9 explains what you can do with each of them.
TABLE 2-9
Setting Read, Write, and Execute Permissions
Permission File Directory
Read View what??™s in the file. See what files and subdirectories it contains.
Write Add files or subdirectories to the directory.
Execute Run the file as a program. Change to that directory as the current directory,
search through the directory, or execute a program
from the directory.
You can see the permission for any file or directory by typing the ls -ld command. The named
file or directory appears as those shown in this example:
$ ls -ld ch3 test
-rw-rw-r-- 1 chris sales 4983 Jan 18 22:13 ch3
drwxr-xr-x 2 chris sales 1024 Jan 24 13:47 test
The first line shows that the ch3 file has read and write permission for the owner and the group.
All other users have read permission, which means they can view the file but cannot change its
contents or remove it. The second line shows the test directory (indicated by the letter d before
the permission bits).


Pages:
206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230