In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-15 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article is about the usefulness of the chgrp and chown commands in Linux. The editor thinks it is very practical, so share it with you as a reference and follow the editor to have a look.
Linux chgrp command
Function: change the group to which the file or directory belongs.
Syntax: chgrp [option] group filename?
This command changes the user group to which the specified file belongs. Where group can be the user group ID or the group name of the user group in the / etc/group file. The file name is a list of files to be changed to the group separated by spaces, and wildcards are supported. If the user is not the owner or superuser of the file, you cannot change the group of the file.
The options of this command mean:
-R recursively changes the grouping of the specified directory and all subdirectories and files under it.
Chown command
Function: change the owner and group of a file or directory. This command is also very common. For example, the root user copies one of his files to the user xu. In order to enable the user xu to access the file, the root user should set the owner of the file to xu, otherwise, the user xu cannot access the file.
Syntax: chown [options] user or group files
Description: chown changes the owner of the specified file to the specified user or group. The user can be a user name or user ID. A group can be a group name or a group ID. Files are a list of files to change permissions separated by spaces, and wildcards are supported.
The options for this command mean the following:
-R recursively changes the owner of the specified directory and all subdirectories and files under it.
-v shows the work done by the chown command.
Thank you for reading! This is the end of the article on "what is the use of chgrp and chown commands in Linux". 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, you can 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.