Date: Tue, 13 Jun 2000 06:10:11 +0200 (CEST) From: clefevre@citeweb.net To: FreeBSD-gnats-submit@freebsd.org Subject: bin/19231: quota/mount commands inconsistency Message-ID: <200006130410.GAA86963@gits.dyndns.org>
next in thread | raw e-mail | index | archive | help
>Number: 19231
>Category: bin
>Synopsis: quota/mount commands inconsistency
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: freebsd-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: current-users
>Arrival-Date: Mon Jun 12 21:20:00 PDT 2000
>Closed-Date:
>Last-Modified:
>Originator: Cyrille Lefevre
>Release: FreeBSD 4.0-STABLE i386
>Organization:
ACME
>Environment:
FreeBSD gits 4.0-STABLE FreeBSD 4.0-STABLE #6: Sun Jun 11 23:24:46 CEST 2000 root@gits:/usr/sys/compile/CUSTOM i386
>Description:
recently, I have tried to setup quotas as usual. the first
things I tries where the "rq" option then the "quota" option.
ok, the "quota" option isn't supported under FreeBSD, as well
as the "rq" option while the later is a little documented in
fstab(5) :
#define FSTAB_RQ "rq" /* read/write with quotas */
so, I use the FreeBSD "userquota" and "groupquota" options.
here is my configuration (/disk0 is my fallback root partition):
# egrep 'disk|\B/\B' /etc/fstab
/dev/ad0s3 /disk0 ufs rw,userquota,groupquota,noauto 1 1
/dev/da0s1a / ufs rw,userquota,groupquota 1 1
/dev/da1s1c /disk2 ufs rw,userquota,groupquota 1 2
/dev/da2s1a /disk1 ufs rw,userquota,groupquota 1 2
/dev/da3s1a /disk4 ufs rw,userquota,groupquota 1 2
# df -k
Filesystem 1K-blocks Used Avail Capacity Mounted on
/dev/da0s1a 1904559 1255135 497060 72% /
/dev/da1s1c 2031922 1372446 496923 73% /disk2
/dev/da2s1a 1904559 1662507 89688 95% /disk1
/dev/da3s1a 1904559 1751524 671 100% /disk4
as I already says, the "rq" option seems to not be supported any
more while mounting an ufs filesystem and the userquota and
groupquota options aren't checked as well to turn quota on while
an ufs filesystem is mounted. you have to turn on quota manually
using quotaon. huh!
# mount -o rq /dev/ad0s3a /disk0
mount: -o rq: option not supported
(well)
# mount -v /disk0
/dev/ad0s3 on /disk0 (ufs, local, soft-updates, writes: sync 2 async 0, reads: s
ync 1 async 0)
(humm... quota are not enabled at mount time!)
# mount | grep /disk1
/dev/da2s1a on /disk1 (ufs, local, with quotas, writes: sync 34 async 110, reads: sync 43 async 5)
(while there are at boot time)
# quotaon -a
(oops, panic! checking for core dump...savecore: no core dump)
(reboot, then same things until quotaon -a)
# quotaon /disk0
# mount | grep /disk0
/dev/da0s1a on / (ufs, local, with quotas, soft-updates, writes: sync 173 async 2939, reads: sync 1779 async 180)
(ok... quota are now enabled)
# umount /disk0
(goto first mount :)
also, if a filesystem isn't mounted at boot time and quotacheck is
requested, quota files are created w/ hole in the mount point of
that filesystem. other quota commands just create an empty file.
so, quotacheck lacks to check if the filesystem is mounted before
to do anything as well as every other quota commands.
# quotacheck -a
(doesn't complain about unmounted /disk0 which is ok)
# ls -l /disk0
total 80
-rw-r----- 1 root operator 2097120 Jun 5 22:09 quota.group
-rw-r----- 1 root operator 2097120 Jun 5 22:09 quota.user
kernel panic seems to arrive when multiple quotaon -a are done
and/or doing quotaoff -a, then quotaon -a.
questions are here :
why did you get rid of the "rq" option ?
if the "userquota" and "groupquota" options are not given, but
"rq" is, isn't it possible to use the same behaviour than other
systems, which is to turn on quota at mount time and not at boot
time and defaulting to userquota to /disk0/quotas in my case ?
of course, more control needs to be done in every quota commands
such as, don't create a quota file if the filesystem isn't mounted.
and mount needs to be completed to activate quotas at mount time.
so, I am right to make these modifications and more if needed,
but before, I want to be sure I'm not wrong somewhere ?
>How-To-Repeat:
see above.
>Fix:
none.
>Release-Note:
>Audit-Trail:
>Unformatted:
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200006130410.GAA86963>
