Hi, 

We use Debian Linux for our Samba file server and for our client laptops. The 
clients mount the Samba shares by CIFS/SMB.

Everything works fine except for one issue: 

If someone opens a document (e.g. .ods) in LibreOffice, nobody else can open 
the same document, not even read only or as a copy!
LibreOffice asks if you want to open it read only or as a copy, but none of 
these options works:
For "read only", nothing happens. And for "as a copy" an empty Writer windows 
appears, even if you tried to open a Calc file.
I can't even run "md5sum mydoc.ods", while another user has opened "mydoc.ods" 
in LibreOffice Calc. It says: "Permission denied".
Only if the first user closes Calc / the document, the next user can open it. 
Deleting the "~lock.<filename>" file is possible for all users! But it doesn't 
help. 
It just makes LibreOffice say "is in use by unknown user" instead of "in use by 
rbarclay". 
(Sorry if the i18n message strings in source code are not exactly the same in 
English as described, we have the German localization and I freely translated 
them.)

There seems to be an issue with the file locking of LibreOffice on CIFS shares 
on Linux.

Has somebody else encountered this issue so far? Is there maybe an issue 
ticket? 

What file locking related config tweaks are available in LibreOffice? 
Preventing concurrent WRITE access is reasonable. But concurrent READ only 
access should be allowed!

Here some information from "smbstatus --byterange" on the file server if a user 
has opened "ipsum.ods" in LibreOffice and noone else can open it concurrently:

Locked files:
Pid          Uid        DenyMode   Access      R/W        Oplock           
SharePath   Name   Time
--------------------------------------------------------------------------------------------------
28991        11141      DENY_NONE  0x80        RDONLY     NONE             
/srv/samba/stuff   .   Wed Jun 25 10:17:28 2025
28991        11141      DENY_NONE  0x12019f    RDWR       LEASE()          
/srv/samba/stuff   lorem/ipsum.ods   Wed Jun 25 10:17:48 2025

Byte range locks:
Pid        dev:inode       R/W  start     size      SharePath               Name
--------------------------------------------------------------------------------
28991      802:59a1180:0   W    0         -9223372036854775808                  
        lorem/ipsum.ods

Thank you for any advice!

Yours,
Reg

-- 
To unsubscribe e-mail to: [email protected]
Problems? https://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: https://wiki.documentfoundation.org/Netiquette
List archive: https://listarchives.libreoffice.org/global/users/
Privacy Policy: https://www.documentfoundation.org/privacy

Reply via email to