How to view and modify file permissions in Linux

Source: Internet
Author: User
In linux, we must use commands to view and modify file permissions. we cannot just click a few times like in windows. next we will briefly introduce the related commands in linux.

View permission commands
You can use the ls-lD command to view the related permissions of the directory, or directly use ls-la

For example

Ls-l www.bitsCN.com // This indicates viewing the www.bitsCN.com Directory
 
Modify permission command

Chmod 777 file name

1. chmod 577/home/stuser-R
2. umask-p 0200
3. chown xxxx yyyy (XXXX is the user name YYYY as the file name)
 
Permission list

-Rw ------- (600) only the owner has the read and write permissions.
-Rw-r -- (644) only the owner has the read and write permissions. the group and others have only the READ permissions.
-Rwx ------ (700) only the owner has the read, write, and execute permissions.
-Rwxr-xr-x (755) only the owner has the read, write, and execute permissions. the group and others have only the read and execute permissions.
-Rwx -- x (711) only the owner has the read, write, and execute permissions. the group and others have only the execution permissions.
-Rw-(666) everyone has the read and write permissions.
-Rwxrwxrwx (777) everyone has the permission to read and write and execute

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.