If i save a file on a samba share, I can not save it a second time or save over another currently existing file on the share. A zero size file is created instead.
I don't have a Samba share, so I can't reproduce this. Please start gscan2pdf with
try to overwrite an existing file on the Samba share, quit, and post the log file.
Please also do the same on a file on a local drive for comparison.
I ran gscan2pdf twice - first time as:
$ gscan2pdf --log=gscan2pdf-smb.log
I scanned two pages (same content twice), saved the document in a directory symlinked to my samba share.
I have gscan set to open docs with acroread on save and everything looked good.
I then scanned the same page twice more, adding to my current doc (did not shutdown) and saved again.
I got no error, except acroread reported the file as damaged when it tried to open it.
I follow the same above process on my local file system and everything worked fine.
I did find out that the second file created on the samba share (the corrupted one) was not zero size - it was, infact, very close to the size of the first tow page scan + the second four page scan instead of being the size of just the 4 page scan like you would expect.
I will attach the smb log, the local fs log, the two page scan from the local fs, the four page scan from the local fs, and the corrupted four page scan as saved to samba.
My current work-around when I have to add pages to a scan after saving (to smb) is to manually delete the saved PDF just before re-saving, otherwize I have to save it to a local file system then manually copy it over the old PDF.
Some more more info that might be helpful:
OS: Ubuntu 12.04 LTS
smb file system mounted via fuse (using nautilus) and symlinked to a local directory.
log from saving over samba
log from saving on local fs
Turns out the demo PDFs are too big for sourceforge (>256K) - I'll find a place to upload them and paste a link
first save on local fs:
second save on local fs - added two pages to first save):
second save to smb file system (added two pages after saving scan of two pages - first file was identical to "first save" above):