[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Checking quotas and the bootup process



>Currently /etc/init.d/quota runs at position 20 in runlevel 2 (default
>installation) and this tends to take a very long time to run at bootup on
>one particular server, and because a lot of the other services tend to
>startup afterwards, either for alphabetic reasons within position 20, or
>they are in a higher position, this particular Linux box is pretty much
>inaccessible and useless whilst checking it's quotas.
>
>Is there any harm in making the quota checking process further down the
>line, after the likes of sendmail and apache have started, or does it run at
>this position for a particular reason (i.e. it's better not to be modifying
>the filesystem whilst it's running?).

Let's imagine that you have quota run as number 99, so sendmail, telnet, and
POP services are all running before it checks.
It will start checking and maybe check /var/spool/mail as one of it's earlier
tasks.  Then it'll move on and check other things, now mail can be delivered
or received without affecting the quota.
So if I have 1M of mail and sendmail delivers another 1M of mail then the
quota system will still think I only have 1M of files.  Then when quotas are
turned on after quotacheck is finished the amount of files I have stored will
not match what the quota system thinks I have.  I am not sure what will
happen if I delete more than 1M of files, I hope that the quota system will
not make 1-2 == 2^32 - 1...
The solution is to only run quotas on /home partition (do not run it on
/var/cache/squid!).  If you have a big /home then split it across partitions
two hard drives (I doubt that quotacheck can benefit from RAID) and run two
quotacheck processes in parallel.

They are talking about adding quotas to the ReiserFS as a file system
feature.  This means that quotas would be in the journal and therefore you
would never need to run quotacheck.  But this won't happen for a while.

-- 
Electronic information tampers with your soul.


Reply to: