I have a disk shared between common users and some special build users.
Is it possible to let the quota system reserve say the last 20G for the build users.
All the instructions & hint I have googled was aiming at setting a max limit on users.
But what I need is a rule that dynamically changes when when the disk free changes. So when the free disk get under 20G, then ordinary users run out of quota, but the build systems will continue.
/// Kjeld Flarup
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
No, quota system cannot do this. At least not easily. However there might be a possibility to workaround your problem. You could have all non-build users in one group and limit the group by size of disk -20 GB. Another possibility would be to use ext3 "reserved space" feature (that is completely orthogonal to quotas) - you could specify user and/or group and reserve for it space on the filesystem using tune2fs.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Grouping the other users would do as a second best solution. I still would like the limit to be dynamic related to the actual free size of disk. Of course I could do that with a cron job, but I need to think the stability of that over.
Otherwise I have thought of the reserved space too. My doubts on that is though the fact that the reserved space also serves as a means to avoid fragmentation of the disk.
/// Kjeld
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Yes, things might get more fragmented when you fill the disk completely. But if the builds are temporary (and you erase those files afterwards) or it does not happen too often, then it need not be a big problem.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi
I have a disk shared between common users and some special build users.
Is it possible to let the quota system reserve say the last 20G for the build users.
All the instructions & hint I have googled was aiming at setting a max limit on users.
But what I need is a rule that dynamically changes when when the disk free changes. So when the free disk get under 20G, then ordinary users run out of quota, but the build systems will continue.
/// Kjeld Flarup
No, quota system cannot do this. At least not easily. However there might be a possibility to workaround your problem. You could have all non-build users in one group and limit the group by size of disk -20 GB. Another possibility would be to use ext3 "reserved space" feature (that is completely orthogonal to quotas) - you could specify user and/or group and reserve for it space on the filesystem using tune2fs.
Thansk Jan
Grouping the other users would do as a second best solution. I still would like the limit to be dynamic related to the actual free size of disk. Of course I could do that with a cron job, but I need to think the stability of that over.
Otherwise I have thought of the reserved space too. My doubts on that is though the fact that the reserved space also serves as a means to avoid fragmentation of the disk.
/// Kjeld
Yes, things might get more fragmented when you fill the disk completely. But if the builds are temporary (and you erase those files afterwards) or it does not happen too often, then it need not be a big problem.