Change Directory-owned user group or file properties under Linux

Source: Internet
Author: User

Intermediary transaction http://www.aliyun.com/zixun/aggregation/6858.html ">seo diagnose Taobao guest cloud host technology Hall

Say recently in toss blog at the same time also toss up blog host, before a user opened a blog virtual host, because he over there speed comparison turtle, so let me help him upload, and I am not a diligent worker, I feel that I download and upload words are not as fast as downloading on the server directly!

The operation has no technical content, download the file directly from the root directory and unzip it, and then move all files in the program directory directly to his web directory.

After a while my friend asked me: "How can I not install the program?" (A friend is a technical madman, excluding the possibility of not running install files.) )

Of course, this situation first takes into account the question of permission, so give him a directory recursive 775 permissions directly.

Friends say it's still not working. Is it not right? Then list the directory and look at it! This found the problem, the original file to the user and group are root, no wonder!

So change the user and the group are the user, OK, everything is normal!

Access to Knowledge:

Change files to group Chgrp:

Syntax:

CHGRP group name file or directory

Example:

CHGRP Test Web/test

Note: Change the group of test directory to test group

Change file owner chown:

Syntax:

Chown [-r] Account name file or directory

Chown [-r] Account name: Group name file or directory

Example:

Chown-r Test Web/test

Note: Change the user of the test directory to the test user recursively

Chown-r test:test Web/test

Note: Change the user and group of the test directory to test users and groups recursively

Change the file familiar chmod:

Syntax:

chmod [-R] [parameter] [directory name]

Example:

Chmod-r 777 Web/test

Description: Changes the Directory test property recursively to 777 properties.

This article is reproduced from the evil guest mood, the original address: http://www.xeker.org/archives/1451

If you want to reprint please retain the above copyright information, the evil guest to thank you!

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.