Issue 25394 - File locking from Windows to Linux does not work
Summary: File locking from Windows to Linux does not work
Status: CLOSED DUPLICATE of issue 17211
Alias: None
Product: General
Classification: Code
Component: ui (show other issues)
Version: OOo 1.1
Hardware: All Windows NT
: P2 Trivial (vote)
Target Milestone: AOO Later
Assignee: tino.rachui
QA Contact: issues@framework
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-02-12 07:10 UTC by shetze
Modified: 2004-02-29 20:20 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description shetze 2004-02-12 07:10:29 UTC
No matter how I configure Samba-3.0.2 on my Debian sarge Linux 2.4.21 system, I
always can open the file with my OOo 1.1.0 (Linux) after this very file has been
opened with OOo 1.1.0 on the NT4 SP6 workstation.
Since I received no confirmation about anybody else having this type of inter-OS
locking with OOo working, this might be simply not implemented.
However, since I have at least one working configuration with above mentioned
environment and M$ Word successfully locking files for OOo on Linux, I suggest
further investigation on how Word gets these locks and possibly implementing
this behavior with OOo on Windows.

Here we go:

Set up your Network such that you have a Samba server and an NT client.
Additionally you might use a Linux client with OOo or you have OOo installed
on the Linux server. Uncomment the SAL_ENABLE_FILE_LOCKING=1 stuff in the
soffice script.
Log into that NT workstation that you are about to replace with Linux
some day in the future. Open OOo and create an new document. Save it on
the group accessible Samba share with group write enabled and keep the
document open.
Next login with Linux as the same user or at least with file system write
access for that file and open the same file localy or on an NFS mount.
See: it opens with writing enabled. For this time, keep in unchanged
and close the document on both Linux and Windows.

Now open the file with OOo on the Linux side first and then try to open
this very file with OOo on your NT workstation.
See: opening the file on the NT side fails with some misleading error message
(my german localized Version says: "Die Datei liegt in einem falschen Format vor")

This happens no matter how I configure Samba.

Now take a look at this:

Configure your samba that OPLOCKS are completely disabled, i.e. make
kernel oplocks = No
oplocks = No
level2 oplocks = No
Dont forget to restart samba after changing the conf.

Open your so much hated old Word97 and create a new document, save it
on the samba share right next to the OOo document.
Just for fun, look at the output of smbstatus -LB and see:
Locked files:
Pid    DenyMode   Access      R/W        Oplock           Name
--------------------------------------------------------------
4992   DENY_NONE  0x2019f     RDWR       NONE  /home/grp1/~WRL0001.tmp
4992   DENY_NONE  0x2019f     RDWR       NONE  /home/grp1/TestDokument2.doc

Byte range locks:
   Pid     dev:inode  R/W      start        size
------------------------------------------------
  4992   00301:420efcb    W  2147483539           1
  4992   00301:420efcb    W  2147483559           1
  4992   00301:420efcb    W  2147483599           1
  4992   00301:420efcf    W  2147483539           1
  4992   00301:420efcf    W  2147483559           1
  4992   00301:420efcf    W  2147483599           1

Now open this Word document with OOo both on the Linux and the Windows side
and see:
The document is opened read-only both on Windows and on Linux.


So, unless we get OOo on Windows lock files for OOo on Linux the smooth
migration path does not work. It might appear that someone has to use M$ Word
on Windows and has to replace both the office and the OS later at the same time.
Not exactly what we would like to do...

Any help is appreciated!
Comment 1 thorsten.martens 2004-02-17 11:43:01 UTC
TM->HRO: Please have a look, thanks.
Comment 2 hennes.rohling 2004-02-18 12:50:35 UTC
Reassigned.
Comment 3 hennes.rohling 2004-02-23 11:41:27 UTC
Reassigned again.
Comment 4 tino.rachui 2004-02-29 20:18:28 UTC
Duplicate

*** This issue has been marked as a duplicate of 17211 ***
Comment 5 tino.rachui 2004-02-29 20:20:17 UTC
closed