In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-04-06 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article mainly introduces the example analysis of linux disk quota, which is very detailed and has certain reference value. Friends who are interested must finish it!
1. Quotas, also known as quotas, are for partitions, neither users nor files, let alone the entire hard disk.
two。 The kernel version must be 2.4 or higher to support it; check to see if the kernel supports quotas.
3.root is not subject to quota restrictions, only ordinary users are restricted.
4. Terms in quotas:
Soft limit: warning limit, which can be broken
Hard limit: maximum available limit, unbreakable
Quota size: in size K and in the number of files
Quota grace date: the grace time for reducing the hard limit back to the soft limit
5. Quotas can be set for users or groups, called:
User quota: usrquota
Set quotas for a single user
Group quota: grpquota
Set quotas for all members of the entire group
6. Configuration steps for quotas:
# vi / etc/fstab # File systems and partitions that need to be mounted when the system starts up
Enable the quota feature when the / home partition is mounted, and modify as follows:
# mount-o remount / home # re-unmount and mount the partition used as quota
# cat / etc/mtab # check whether disk quotas are enabled for mounted partitions
Note: / etc/mtab this file is the partition that has been mounted after the system boot.
Quota detection: detects quotas in the system, creates quota files under the partition and writes system quota information
# useradd us1
# quotacheck-cavug
# ll / home # check whether / home produces two quota database files
Edit the quota size for a user or group
# edquota-u us1
# edquota-g us1
View user and group quota report
# repquota-a
# repquota-ag
Enable quota featur
# quotaon-avug
Test the user's quota
# su-us1 / / switch normal user test user quota
$cp / bin/* / home/us1 / / copy files to test the effect of quota limits
# repquota-a / / View quota report
Check the used size of the current directory
# du-h
Modify the grace time of the quota (for the entire partition, the time unit can be days, hours, minutes, seconds)
# edquota-t
Quota replication (multiple target users can be specified at the same time)
# edquota-p us1 us2 us3 us4 us5
The above is all the contents of the article "sample Analysis of linux disk quotas". Thank you for reading! Hope to share the content to help you, more related knowledge, welcome to follow the industry information channel!
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.