Samba 1.9.17 fails to truncate share mode file (fwd)
Boorman Tim
Boorman.Tim at Lusis.com
Wed Oct 1 10:50:52 GMT 1997
This problem appears to have been fixed in 1.9.17p2.
Regards,
Tim
> Tim Boorman
> UNIX Systems Support
> Lusis Limited, Technology Drive, Bridgend Science Park, Bridgend,
> United Kingdom CF31 3UJ
> Extension: 44966
> Direct Line: +44 (0)1656 765966
> Mobile: +44 (0)468 647495
> Email: boorman.tim at lusis.com
>
>
> -----Original Message-----
> From: George White [SMTP:gwhite at bodnext.bio.dfo.ca]
> Sent: 26 September 1997 11:59
> To: Boorman Tim
> Cc: 'Wijnand Dijkstra'; 'samba at listproc.anu.edu.au'
> Subject: RE: Samba 1.9.17 fails to truncate share mode file (fwd)
>
> To recap:
>
> Samba 1.9.17 and 1.9.17p1 on systems that don't support the new shared
> memory locking creates a large number of error messages of the form:
>
> Sep 23 11:22:03 bodnext smbd[15358]: ERROR: del_share_mode: failed to
> ftruncate share mode file /usr/local/samba/var/locks/share.1544.132871
> to size 56 (Permission denied)
> Sep 23 11:22:04 bodnext last message repeated 2 times
>
> I looked at the files where the call was failing, and in a small
> sample, the files were always at the desired length, so my first
> guess was that ftruncate was failing when the new size was the
> same as the actual size of the file. I hacked locking.c so that
>
> a. ftruncate was only called when the new size was less than the
> actual size
> b. the error messages displayed the old and new sizes
>
> This greatly reduced the number of log messages, but I was now
> able to verify that ftruncate was failing when the new size was less
> than the actual size. I now suspect that ftruncate fails when the
> file
> not open for writing.
>
> The attached locking.c adds code to make sure the file is open for
> writing
> before ftruncate is called. I have used this for a day without any
> ftruncate failure messages.
>
> --
> George White <aa056 at chebucto.ns.ca> <WhiteG at mar.dfo-mpo.gc.ca>
> Bedford Inst. of Oceanography, Nova Scotia, Canada. tel:
> 902.426.8509 << File: >>
More information about the samba
mailing list