On Tue, May 17, 2011 at 08:06:46PM -0400, James Cloos wrote:
> >>>>> "MC" == Markos Chandras <[email protected]> writes:
> 
> MC> Can you please provide some examples that require /var/lock to
> MC> survive a reboot?
> 
> Not everything is part of the distribution.
> 
> The one which first comes to mind are lock files placed to prevent
> certain cron-initiated jobs from running right after a reboot.
> 
> Or locks preventing certain daemons from accepting connections.
> 
> Such locks often are used to protect net bandwidth when it is needed
> for real-time use.  A reboot of some random box on the lan should not
> break such locks.

According to what I am reading in the fhs, /var/lock is not sharable
between multiple systems. Also, the contents of the lock file is
supposed to be the pid of the process that holds the lock [1].

Given that, a lock will automatically be invalid when you reboot, so it
should be forgotten about on a reboot.

William

[1] http://www.pathname.com/fhs/pub/fhs-2.3.html#VARLOCKLOCKFILES

Attachment: pgpLHHQsLku6r.pgp
Description: PGP signature

Reply via email to