chmod command--chmod 755 with chmod 4755 difference _php Tutorial

Source: Internet
Author: User
The difference between 755 and 4755

chmod is a command that sets file permissions under Linux, followed by a number that represents the permissions of different users or groups of users.

It is usually three digits:
The first number indicates the permissions of the file owner
The second number indicates the permissions of other users who belong to the same user group as the file owner
The third number represents the permissions of the other user groups.

Permissions are divided into three types: Read (r=4), write (w=2), execute (x=1). The combination also has a readable executable (rx=5=4+1), a readable writable (rw=6=4+2), and a readable writable executable (rwx=7=4+2+1).

Therefore, chmod 755 sets the user's permissions to:

1. File owner readable writable executable
2. Other user-readable executables that belong to the same user group as the file owner
3. Other user groups can read the executable

The difference between chmod 4755 and chmod 755 is that it starts with a bit more, and this 4 means that other users have the same permissions as the owner when they execute the file.

For example: The root user has created an Internet authentication program Netlogin, if other users want to use the Internet access to the program, it requires the root user to run chmod 755 netlogin command to enable other users to run Netlogin.

However, Netlogin may need access to some files that only the root user has access to, and other users may not be able to access the Internet because they do not have enough permissions to perform netlogin.

In this case, you can use the chmod 4755 Netlogin to set up other users in the execution netlogin also have root user rights, so that the internet smoothly.

http://www.bkjia.com/PHPjc/477383.html www.bkjia.com true http://www.bkjia.com/PHPjc/477383.html techarticle the difference between 755 and 4755 chmod is a command that sets file permissions under Linux, followed by a number that represents the permissions of different users or groups of users. Typically three digits: the first number indicates that the file is all ...

  • 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.