Linux Disk Quota 1. the disk quota is restricted only for the entire partition: When the disk quota is actually run, it is restricted for the entire partition. For example, if/dev/hda5 is loaded under/home, all directories under/home are restricted.
In a production or work environment, you may encounter the following situation: in a multi-person, multi-task environment, multiple people share a disk space, some people may put a lot or a lot of files in the same space, which leads to a sharp
Disk quotas
The site service will generally set quota limits for the site service domain name space;
The Mail service sets the disk quota limit for each mailbox user in the mail service;
The file service sets a quota limit for
1. Check kernel conditionsCheck whether the current kernel supports quota and the current kernel profile is in/bootIf the current kernel does not support quota, you will need to recompile the kernel to compile quota supports into the core:File
1. What is quotaSimply put, limit the amount of disk space users use.Because Linux is a multi-user multitasking operating system, many people share disk space, in order to allocate disk space reasonably, so there is a quota appearance.Use of
Quoto:Disk Quota: limits the usage of a user on a disk!Limited space size. Limited number of filesSoft and Hard LimitsSoft limit: grace time, which can exceed the disk quota within a certain period of time!Hard limit: you cannot exceed the disk
I. Installation
Yum install quota
Ii. Configuration
1. Create a New partition sdb1 and format it
2,
[[Email protected]/] # mkdir/common
[[Email protected]/] # Mount/dev/sdb1/common/
[[Email protected]/] # Mount
/Dev/sdb1 on/common type ext4
Quoto: Disk quota: limits the usage of a user on a disk! Limited space size. limited file quantity soft limit, hard limit soft limit: gracetime, can exceed the disk quota within a certain period of time! Hard limit: you cannot exceed the disk quota!
Five users, each with a quota of 10MB (hard) and 8MB (soft) per user0Environment[Email protected] ~]# uname-aLinux localhost.localdomain 2.6.32-431.el6.x86_64 #1 SMP Fri Nov 03:15:09 UTC x86_64 x86_64 x86_64 gnu/linux[Email protected] ~]#
1 usage limits for disk quotasFor the entire partition only: When the disk quota is actually running, it is limited for the entire partition, for example, if/DEV/HDA5 is loaded under/home, then all directories under/home are restricted. Valid only
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.