The ls -l
command gives you the access mode information of a directory or file. Here are the key points of how to read the information.
Based on the three owner statuses, the access mode is different for each one. By running the ls -l command, you'll see 9 characters defining the access mode.
There are three types of permissions (access modes). Read (r
), Write (w
) and Execute (x
). The meaning of permissions is slightly different for files and directories.
For files,
r
) : Be able to read the filew
) : Be able to edit the filex
) : Be able to run the command defined in the fileFor directories,
r
) : Be able to list file and directory names under the directory (read the contents of the directory)w
) : Be able to create and remove files, and change the name of files in the directoryx
) : Be able to set the directory as the current working directory (CWD)The ls -l
command gives you the access mode information of a directory or file. Here are the key points of how to read the information.
Based on the three owner statuses, the access mode is different for each one. By running the ls -l command, you'll see 9 characters defining the access mode.
There are three types of permissions (access modes). Read (r
), Write (w
) and Execute (x
). The meaning of permissions is slightly different for files and directories.
For files,
r
) : Be able to read the filew
) : Be able to edit the filex
) : Be able to run the command defined in the fileFor directories,
r
) : Be able to list file and directory names under the directory (read the contents of the directory)w
) : Be able to create and remove files, and change the name of files in the directoryx
) : Be able to set the directory as the current working directory (CWD)