On Wed, Mar 16, 2016 at 11:29 AM, Matthew Miller
<mattdm(a)fedoraproject.org> wrote:
On Tue, Mar 15, 2016 at 04:01:28PM -0600, Chris Murphy wrote:
> A survey could be useful for Fedora 25+ but in that case I'd be
> curious at least as much about what sysadmins don't know. For example,
> I've yet to hear a sysadmin suggest quotas for var or opt instead of
> separate partitions. Have they used quotas? Why not? Separate var opt
> may be common, but that doesn't mean it's optimal.
I know it's just an example, but I can't resist giving personal
feedback. :)
Some of it may come down to "linux quotas are a pain to manage". So
more resources for making that better might indeed help.
XFS project quotas are a pain. Btrfs is easy but also on its 3rd
revision and there hasn't been enough testing. Ext4 project quotas are
new and I'm not familiar.
The point is they're also highly variable, getting this abstracted
from the user would improve their use since it'd matter less what
filesystem is being used.
But, also, /var is a combination of users-filling-up space and root
doing it, and the latter is usually not constrained by quotas.
Last time I checked, hard limit applies to root, whereas the soft
limit doesn't (i.e. soft limit is when there are scary warnings).
There might be differences between project, user and group quotas
applying to root.
[root@localhost project_quota_test1]# xfs_quota -c df
Filesystem 1K-blocks Used Available Use% Pathname
/dev/sdb 83845120 157980 83687140 0% /xfs_local
/dev/sdb 102400 124928 9223372036854753280 122%
/xfs_local/project_quota_test1
[root@localhost project_quota_test1]# dd if=/dev/zero of=test100MB
bs=1M count=100
dd: error writing ‘test100MB’: No space left on device
79+0 records in
78+0 records out
81788928 bytes (82 MB) copied, 0.163849 s, 499 MB/s
[root@localhost project_quota_test1]# xfs_quota -c df
Filesystem 1K-blocks Used Available Use% Pathname
/dev/sdb 83845120 237748 83607372 0% /xfs_local
/dev/sdb 102400 204800 9223372036854673408 200%
/xfs_local/project_quota_test1
Too many
sysadmins woken in the middle of the night because some out-of-control
log file wedged things up. :) And even if a quota were applied to them,
as far as I know, journald's heuristics for space usage work on the
filesystem level and don't check quotes.
Journald is self-limiting and configurable so neither separate var nor
quota need apply. Also, Server uses rsyslog for persistent logging,
while journald's log is volatile.
If separate var volume, rsyslog (or anything else) can fill up var,
and now everything that writes to var will receive enospc and get
pissed. I'm not sure what problem separate var really solves when it
creates a problem for other processes somewhat indiscriminately. A
quota on var/log limits only rsyslog, everything else can keep
working.
--
Chris Murphy