Subject: bin/1790: quota still uses ufs
To: None <gnats-bugs@gnats.netbsd.org>
From: Andrew Wheadon <andrew@wipux2.wifo.uni-mannheim.de>
List: netbsd-bugs
Date: 11/25/1995 15:34:32
>Number: 1790
>Category: bin
>Synopsis: quota doesn't work and still seems to use ufs.
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: bin-bug-people (Utility Bug People)
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Sat Nov 25 10:05:00 1995
>Last-Modified:
>Originator: Andrew Wheadon
>Organization:
The cost of living hasn't affected it's popularity. (unknown)
current release=doc host=wipux2.wifo.uni-mannheim.de \ "NetBSD-current mirror"
hostbase=/mit/ftp/pub/NetBSD base=/usr prefix=/usr backup delete use-rel-suffix
>Release: 1.1
>Environment:
System: NetBSD wipux2 1.1 NetBSD 1.1 (WIPOOL) #1: Thu Nov 23 14:54:52 MET 1995 toor@wipux2:/src/src/sys/arch/i386/compile/WIPOOL i386
>Description:
if type 'ffs' is used in /etc/fstab
quota -v son00685 (a user who has his quota set with 'edquota')
lists: Disk quotas for user son00685 (uid 13261): none
The manual quota.1 also only mentions 'UFS' and nfs
instead of 'FFS'
edquota correctly lists:
Quotas for user son00685:
/var: blocks in use: 3448, limits (soft = 3000, hard = 1000)
inodes in use: 1, limits (soft = 50, hard = 10)
/home: blocks in use: 1203, limits (soft = 8000, hard = 4000)
inodes in use: 22, limits (soft = 400, hard = 200)
>How-To-Repeat:
Use 'ffs' instead of old 'ufs' in /etc/fstab
Install quotas for any user and run 'quota -v user'
>Fix:
run patch in usr/src/usr.bin/quota. (btw it doesn't
fix 'fstab.5' which still refers to ufs, and doesn't
mention 'ffs')
diff -C 4 old/quota.1 ./quota.1
*** old/quota.1 Sat Nov 25 15:30:03 1995
--- ./quota.1 Sat Nov 25 15:30:10 1995
***************
*** 111,119 ****
daemon on the
.Nm NFS
server.
For
! .Nm UFS
filesystems, quotas must be turned on in
.Pa /etc/fstab .
If
.Nm quota
--- 111,119 ----
daemon on the
.Nm NFS
server.
For
! .Nm FFS
filesystems, quotas must be turned on in
.Pa /etc/fstab .
If
.Nm quota
diff -C 4 old/quota.c ./quota.c
*** old/quota.c Sat Nov 25 15:19:24 1995
--- ./quota.c Sat Nov 25 15:28:01 1995
***************
*** 451,460 ****
}
if (strncmp(fst[i].f_fstypename, "nfs", MFSNAMELEN) == 0) {
if (getnfsquota(&fst[i], NULL, qup, id, quotatype) == 0)
continue;
! } else if (strncmp(fst[i].f_fstypename, "ufs",
! MFSNAMELEN) == 0) {
/*
* XXX
* UFS filesystems must be in /etc/fstab, and must
* indicate that they have quotas on (?!) This is quite
--- 451,461 ----
}
if (strncmp(fst[i].f_fstypename, "nfs", MFSNAMELEN) == 0) {
if (getnfsquota(&fst[i], NULL, qup, id, quotatype) == 0)
continue;
! } else if ((strncmp(fst[i].f_fstypename, "ffs",
! MFSNAMELEN) == 0) || (strncmp(fst[i].f_fstypename, "ufs",
! MFSNAMELEN) == 0)) {
/*
* XXX
* UFS filesystems must be in /etc/fstab, and must
* indicate that they have quotas on (?!) This is quite
>Audit-Trail:
>Unformatted: