Fw: File locks when restarting smb

Simon Allenby simona at projtel.co.uk
Tue Apr 17 14:58:50 GMT 2001


Hi,

Is there a known problem with file locks when Samba restarts?

I have several servers happily running Samba on RH Linux, and several
hundred clients running M$ Win9x.
There are always a large number of open files, and I am currently migrating
the data off several NT servers and onto the Samba ones. This has meant
changing the smb.conf file on a regular basis.

I am restarting Samba using "/etc/rc.d/rc5.d/K35smb restart"

If a user has a file open, with read-write permissions, and then Samba is
restarted, these permissions are lost. The first Windows client still thinks
it has RW permissions on the file, however at this point a second user could
open the same file, gaining the permissions. The first user would then not
be able to save the file (correctly IMO) even though Word/Excel thinks it
can. If the second user changes the file, and saves and closes it, the lock
is removed, and the first user is free to overwrite the file again (losing
the second user's changes). Worse still, on several recent occasions, the
file has corrupted on the server, during saves after a Samba restart. This
predominently happens in Excel, although I believe it has happened in Word
as well.

Should/could Samba save it's open locks, and re-read them under a restart (I
appreciate that this wouldn't be desired all of the time), or is there
another way of getting Samba to re-read the smb.conf and setting up new
shares without killing all of the active connections and therefore locks?

Your help is greatly appreciated.

Thanks in advance,


Simon

-------------------------------------------------------------
Simon Allenby - IT - Project Telecom plc
email - simona at projtel.co.uk
Direct line 01636 615200





 ------------------------------------------------------------
 This communication is confidential and is intended
 only for the person to whom it is addressed.
 If you are not that person you are not permitted to
 make use of the information and you are requested
 to destroy the copy in your possession immediately.
 ------------------------------------------------------------




More information about the samba-technical mailing list