Hallo René

On Tue, 15 Nov 2005, Rene Engelhard wrote:

Tomas Pospisek wrote:
When I save onto a shfs filesystem, oowriter will merrily "save" it, but
in reality leave a file of length 1 without complaining. This looks very
similar to problems with ooo 1.x where ooo was at least complaining that
there were "errors" without it being clear what "errors" these were.

Did you try closing the file / quitting OOo?

I just tried it - I created a basic file only containing "Test"; shfs mounted
with "shfsmount [EMAIL PROTECTED]:/home/rene -ouid=1000,gid=1000" -
and while OOo was still running/the file still open ls
indeed showed 1 byte (and the file was not complete). But after I closed
the file (or quit OOo) the file had a "normal" size and could be opened
then again.

I can confirm this.

Maybe it is some cache issue or shfs not noticing that there is
something new bigger than 1 byte while the file is open?

I don't have an idea. However, the fact that when closing the document OOo will freeze for an instant brings me to the "educated guess" that either:

* OOo for some unknown reason delays writing the file out until the
  document is closed
* OOo doesn't close or flush the file when writing it and doesn't do it
  until the document is closed

I've checked whether shfs's behaveour is different to standard FSs with respect to flushing. When running the following script:

        #!/usr/bin/perl
        open(F, ">/tmp/tpo-test.txt");
        # open(F, ">/mnt/shfs/tmp/tpo-test.txt");
        print F "test";     print "written"; <>;
        $| = 1;             print "flushed"; <>;
        close F;            rint "closed"; <>;

ls -l will show a zero-size file until the file is /closed/ (even flushing it won't change the size). This behaveour is identical on ext3 and on shfs.

I'd have tried with cachesize=0 but that freezes the machine...
(#286723)

Haven't tried that.

(shfs module from sarge, mount done inside a sid chroot)

shfs-source 0.35-3 on sarge with a 2.4.22 kernel, i568.
*t

--
--------------------------------------------------------
  Tomas Pospisek
  http://sourcepole.com -  Linux & Open Source Solutions
--------------------------------------------------------

Reply via email to