Return to BSD News archive
Newsgroups: comp.os.386bsd.questions Path: sserve!newshost.anu.edu.au!munnari.oz.au!news.Hawaii.Edu!ames!elroy.jpl.nasa.gov!decwrl!usenet.coe.montana.edu!netnews.nwnet.net!ns1.nodak.edu!plains.NoDak.edu!tinguely From: tinguely@plains.NoDak.edu (Mark Tinguely) Subject: Re: [NetBSD] Problems with quota Sender: usenet@ns1.nodak.edu (Usenet login) Message-ID: <CAy2Dv.nq0@ns1.nodak.edu> Date: Thu, 29 Jul 1993 21:01:07 GMT References: <GSPIEGEL.144.743456044@bsa3.kent.edu> <CGD.93Jul23155021@erewhon.cs.berkeley.edu> <CAp3nq.6ns@cyb.cojones.com> Nntp-Posting-Host: plains.nodak.edu Organization: North Dakota State University Lines: 62 In article <CAp3nq.6ns@cyb.cojones.com> loodvrij%cyb@fredbox.cts.com writes: >In article <CGD.93Jul23155021@erewhon.cs.berkeley.edu> cgd@erewhon.CS.Berkeley.EDU (Chris G. Demetriou) writes: >> >>i've never tried quotas in NetBSD (!!), but from what i know, >>they *should* work... >> >They didn't for me. I got everything set up to the point where nothing was >giving any errors. Redid the kernel from scratch, uncommented the lines >from /etc/rc, added the stuff to /etc/fstab, and then chose a poor unsuspecting >user and gave him a pitifully low quota on the usr partition. su'd to him and >copied the kernel into his directory. Nada. No warning, errors, nothing. maybe you did not complete the setup, here is a step-by-step instructions to get them to work: 1) make a kernel with quota option installed 2) edit /etc/fstab and include the kinds of quotas you want, below I used "userquota", you could also add "groupquota". /dev/wd0h /usr ufs rw,userquota 1 2 3) for each filesystem that is in /etc/fstab that uses quota, create the file "quota.user" (and "quota.group if appropriate). Above I have user quotas in the /usr filesystem, so I would: # touch /usr/quota.user 4) scan filesystem for files ownership (and/or group ownership). # quotacheck -a 5) now you can add individual quota limits, if you want to add the same quotas to the many people, then make a template and replicate the template. If they change for each user, then edit seperately. # edquota tinguely (an editor is kicked up and says something like: Quotas for user tinguely: /usr: blocks in use: 11876, limits (soft = 0, hard = 0) inodes in use: 891, limits (soft = 0, hard = 0) a limit of 0 means "unlimited" change these to the appropriate number of blocks. A soft limit generates a warning, and can be exceed for period of time (7 days?), after which time a soft limit is treated like a hard limit. A hard limit denies new writes. to replicate a template (for this example let us assume "tinguely is the template): # edquota -p tinguely user1 user2 user3 ... userN 6) turn quotas on (usually done in the /etc/rc file, but turn it on manually so you do not have to reboot right now: # quotaon that should take care of setting up quotas. you can look at the status of use of files with repquota, the -a option lists all filesystems with quotas. --mark.