In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article will explain in detail how the Centos7 system uses chmod to modify file permissions. The editor thinks it is very practical, so I share it for you as a reference. I hope you can get something after reading this article.
Files in the Centos7 operating system are divided into user (user) permissions, group (group) permissions, and other user (other) permissions, referred to as ugo, so it is often necessary to modify the permissions of the files when using the Centos7 system.
The file user group permissions of the Centos7 system are mainly divided into the following categories:
U User, the owner of a file or directory
G Group, the group to which the file or directory belongs
O Other, except for the owner of the file or directory or the group to which it belongs, all users fall within this scope
An All, that is, all users, including owners, groups, and other users.
Among them, there are three kinds of permissions for files, namely, read (r), write (w), and execute (x).
R read permission, numeric code "4"
W write permission, numeric code "2"
X execute or switch permissions, numeric code "1"
-without any permission, the number code is "0"
S Special function description: change the permissions of a file or directory.
If you need to change the file permissions, you can generally change the file permissions through the chmod command, there are two ways to modify file permissions, syntax format: chmod (option) (parameter), this article takes the centos7 system where RAKsmart VPS is located as an example to give you a simple talk.
The first, alphabetical form:
Directly grant permissions: chmod u=rwx demo
Second, add or subtract one or more permissions: add permissions to use "+", remove permissions "-"
Chmod gripx, Gripw demo.
Digital form:
R = read attribute / / value = 4
W = write attribute / / value = 2
X = execution attribute / / value = 1
For example: chmod 761demo, all permissions are set for the owner, read and write are set for the group, and execute permissions are set for others.
On "Centos7 system how to use chmod to modify file permissions" this article is shared here, I hope the above content can be of some help to you, so that you can learn more knowledge, if you think the article is good, please share it out for more people to see.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.