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

Re: Re[2]: LCK and reboot

JOHNR wrote:
> I have had this issue when using the application 'dip' to control dialup 
> SLIP/PPP connections.  It puts lock files in the same directory and would not 
> allow itself access to the modem port if the .LCK file was present.  As you 
> probably figured, the .LCK file does not get deleted unless the application(s) 
> that work with it terminate cleanly and clean up after themselves.

The application can not always remove the lockfile (some people kill
dip using 'kill -9 <dip_pid>'). But that's no problem since they all
use ASCII lockfiles. Programs like slattach or dip check if the process
with the pid mentioned in the ASCII lockfile is still running. If the
process does not exist anymore it will replace the lockfile.

> Since at boot time no locks should be "on", you could enter a command at boot 
> time that discriminately (or indiscriminately) removes all .LCK files from the 
> directory.

I think the latest sysvinit package (2.59-2) removes the contens (only
files) of directories like /var/run or /var/lock.


 Peter Tobias                                EMail:
 Fachhochschule Ostfriesland                 tobias@et-inf.fho-emden.de
 Fachbereich Elektrotechnik und Informatik   tobias@perseus.fho-emden.de
 Constantiaplatz 4, 26723 Emden, Germany

Reply to: