the quota question ... one user with >2 TB owned files (but no quota set)

Oliver Fromme olli at lurza.secnetix.de
Fri Jul 11 17:52:14 UTC 2008


Miroslav Lachman wrote:
 > Juri Mianovich wrote:
 > [...]
 > > I haven't heard anything - which is not surprising, since it
 > > doesn't sound like many people are using quotas these days.
 > >
 > > Does anyone have any general thoughts as to whether this will be
 > > dangerous or not ? I know (I assume) that repquota output for my
 > > root and www users will be broken, and that's fine - I just want to
 > > make sure that as soon as one user goes over 2TB of owned files the
 > > filesystem doesn't trash itself.
 > >
 > > Can the quota subsystem failing in some way cause data loss /
 > > filesystem inconsistencies ?
 > 
 > I think there are not so many users running similar configuration, it 
 > means not much experiences. But you can try your own test easily. Just 
 > install some test machine and try it with large sparse files

That doesn't help, because only physically allocated space
accounts towards quotas.  An sparse file of 1 GB that
consists entirely of zeros uses only 48 KB of physical
disk space (with default UFS2 newfs parameters), so it
uses only 48 KB from your quota, not 1 GB.

 > (something like dd if=/dev/zero of=sparse-file bs=1 count=1 seek=1024k 
 > for 1M sparse file)

There's an easier way to do that:

truncate -s 1m sparse-file

Best regards
   Oliver

-- 
Oliver Fromme, secnetix GmbH & Co. KG, Marktplatz 29, 85567 Grafing b. M.
Handelsregister: Registergericht Muenchen, HRA 74606,  Geschäftsfuehrung:
secnetix Verwaltungsgesellsch. mbH, Handelsregister: Registergericht Mün-
chen, HRB 125758,  Geschäftsführer: Maik Bachmann, Olaf Erb, Ralf Gebhart

FreeBSD-Dienstleistungen, -Produkte und mehr:  http://www.secnetix.de/bsd

"Clear perl code is better than unclear awk code; but NOTHING
comes close to unclear perl code"  (taken from comp.lang.awk FAQ)


More information about the freebsd-fs mailing list