Linux disk quota-related directives

Source: Internet
Author: User
Tags disk usage inode usage

The main functions of 1.Quota are:

1) Limit the maximum disk quotas that a group of groups can use

2) limit the maximum disk quota for a user

3) Link to make the message available as a restricted quota (change/var/spool/mail this path)

2.Quota Usage Limits

1) only available for the entire filesystem

2) core must support quota

3) Quota record file

4) only for the general identity of the user effective, root is not set quota, because the entire system of all the data is almost his

The 3.quota limit project for the entire filesystem is divided into the following sections:

1) capacity limit or file number limit (block or inode), which limits the inode usage, can manage the number of files that the user can establish, limit the block usage, and manage the limit of users ' disk capacity.

2) Flexible persuasion and hard planning: Regardless of the inode/block, there are two limit values, respectively, soft and block, usually hard limit value is higher than soft. The meanings of these two limiting values are:

a) Hard: Indicates that the user's usage will never exceed this limit, and once this value is exceeded, the system will lock the users ' disk rights

B) Soft: Indicates that the user can use the disk normally when it is below the soft limit, but if it exceeds the warning message that the disk is about to be full, it will give a grace time. If the user releases space within the grace period, the grace time is stopped.

3) Grace time: The general preset is 7 days, if the user does not take any action during the grace time, then the soft limit value will replace the hard value as the limit of quota.

4.quota record files: Quota is the analysis of the overall file system, each user (group) has the total number of files and total capacity, and then record the data in the top-level directory of the file system, and then in the record file with each account (or group) limit values to standardize disk usage. Scan a file system with support for the quota parameter (Usrquota,grpquota) using the Quotacheck command

5.quotacheck [-AVUGFM] [/mount_point]: Scan the file system and establish quota log files, parameters:

1)-A: Scan all in/etc/mtab, containing quota support filesystem, plus this parameter,/mount_point not finish, because scan all the filesystem

2)-U: For users to scan the use of files and directories, will establish Aquota.user

3)-G: For the use of Group scan files and directories, Aquota.group will be established.

4)-V: Displays information about the scanning process

5)-F: Force scan of file system and write new quota configuration file (dangerous)

6)-M: The file system is forced to read and write, and is used only in special cases.

General-AUVG combination use

5.quotaon [-avug];quotaon [-avug] [/mount_point]: Start quota service: parameters,

1)-u: Start quota for user (Aquota.user)

2)-G: Start quota for group (Aquota.group)

3)-V: Displays the boot process information

4)-A: According to the/etc/mtab within the filesystem set to start the relevant quota, if not add-a, then you need to add a specific filesystem.

6.quotaoff [-a];quotaoff [-ug][/mount_point]: Off Quotaoff service, Parameters:

1)-A: All filesystem quota are closed (according to/etc/mtab)

2)-u: Close user quota only for the back of the/mount_point

3)-G: Close group Quotaon only for the next/mount_point

7.edquota [-u username][-g gourpname];edquota-t; edquota-p model Account-U new account: Edit account number, group limit and grace time, through call VI to set, parameters,

1)-U: After the account name, you can enter the Quota edit screen (vi) to set the username limit value

2)-G: followed by the group name, you can enter the quota edit face (vi) to set the GroupName limit value

3)-T: can modify the wide time limit

4)-P: Copy templates, the template account for already exists and has been set up quota users, meaning "the model account this person's quota limit value to the new account format as" Edquota-p username-u NewUser "

8.quota [-uvs] [Username];quota [-gvs] [groupname]: Single user quota report, Parameters:

1)-u: can be followed by username, indicating that the user's quota limit value is displayed. If the username is not received, the quota limit value of the performer is displayed.

2)-G: The following can be groupname, indicating that the group's quota limit value is displayed

3)-V: Displays the quota value of each user in filesystem

4)-S: Use a multiple of 1024 to specify units, and display units such as M

9.repquota-a [-vugs]: report on quota of file system, parameters:

1)-V: The output data will also have filesystem related details

2)-u: Displays the user's quota limit (this is the default value)

3)-G: Shows the quota limit for individual groups

4)-S: Display results using M,G

10.warnquota: Send a warning message to the person exceeding the limit.

11.setquota [-u|-g] name block (soft) block (hard) inode (soft) inode (hard) file system: Set the quota limit directly in the instruction

This article is from "Tiger Brother's Blog" blog, please be sure to keep this source http://7613577.blog.51cto.com/7603577/1598294

Linux disk quota-related directives

Related Article

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.