Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 02 Dec 2018 02:02:14 +0100
From:      Markus Hoenicka <>
Subject:   Re: ROX-Filer: overwriting a file on an USB drive truncates it
Message-ID:  <>
In-Reply-To: <>
References:  <> <>

Next in thread | Previous in thread | Raw E-Mail | Index | Archive | Help
Am 2018-12-01 14:36, schrieb Dave:
> On Thursday, 29 November 2018 00:23:12 GMT Markus Hoenicka wrote:
>> Hi,
>> I've recently upgraded my laptop to:
>> FreeBSD wombat 11.2-RELEASE-p4 FreeBSD 11.2-RELEASE-p4 #0: Thu Sep 27
>> 08:16:24 UTC 2018
>>  amd64
>> I've also updated all installed packages.
>> I keep running into a nasty file copying bug that does not seem to 
>> have
>> occurred previously. Result is that overwriting an existing file on an
>> USB drive causes this file to be truncated instead of being 
>> overwritten,
>> which means data loss.
>> How to reproduce:
>> After logging in, I start an Xfce session manually:
>> startxfce4 --with-ck-launch
>> mount stick in an xterm, as per handbook. Note that I've set up user
>> mounting of USB drives:
>> mount -t msdosfs -o -m=644,-M=755 /dev/da0s1 /stick/markus
>> open source directory (on hard drive) in a ROX-Filer window
>> open target directory (on usb drive) in another ROX-Filer window
>> drag&drop a file from source over an existing copy on target
>> dialog box asks if it is ok to overwrite which I acknowledge
>> ROX-Filer window shows the correct file size immediately after 
>> copying,
>> and after rescanning the directory. ls -al /stick/markus/targetdir 
>> also
>> shows the correct file size at this point.
>> umount /stick/markus fails because the device is busy. fstat shows 
>> that
>> the ROX-Filer process keeps it busy
>> now I can either use umount -f /stick/markus to forcibly unmount the
>> stick, or I log out of the X session and then use umount /stick/markus
>> without problems
>> then mount the stick again as above, or try on a different computer
>> ls -al /stick/markus/targetdir shows a target file size of zero.
>> It appears that the new data are never flushed to the disk. I've even
>> tried to run umount /stick/markus before umount -f /stick/markus, as
>> this should perform a flush according to the umount man page. This bug
>> appears to be specific to ROX-Filer. I could not reproduce this using
>> Thunar, or plain ol' cp. This bug also appears to be specific to USB
>> target drives, as I cannot reproduce this when overwriting files on 
>> the
>> hard drive. I do not think the problem is related to a faulty file
>> system on the target drive as I can reproduce this with just about any
>> thumbdrive and external disk lying around.
>> I've been using ROX-Filer for ages, but I've noticed that neither
>> mailing lists nor bug tracker seem to be active. Is it about time to
>> move on?
>> thanks
>> Markus
> I've seen similar issues with various filemanagers over the years
> including Konquerer and Dolphin.  I always just assumed it was a
> feature of the way filemanagers worked so always closed the file
> manager windows linked to the mounted device before unmounting it
> or at least select a directory that is not part of the mounted
> device.
> I never tried doing a forced umount while the filemanager had a
> link to the mounted device.
> _______________________________________________
> mailing list
> To unsubscribe, send any mail to 
> ""

Hi Dave,

thanks for the input. In fact I did close the ROX-Filer windows before 
trying to unmount the stick. I just forgot that I had a ROX panel 
running which shares the same process as the file manager windows. 
Therefore the process kept the stick busy even after closing the file 
manager windows. I've removed the panel and tried again. Mount stick, 
copy file over existing file on stick between two ROX-Filer windows, 
close both windows, check there is no ROX process, check file size with 
ls -al (still correct at this point), unmount stick, mount it again - 
zero byte length. Same test with cp succeeds. It feels kinda scary if a 
no longer existing file manager process affects the state of a file on a 
stick - the medusa touch??. Fun fact: there is no such problem with 
ROX-Filer on my Debian box. Both use the same version 2.11.

Looks like I'll have to switch to some other file manager for the time 
being. Any suggestions? I'll be happy to provide additional debug info 
if someone wants to take a stab at it - this is unfortunately above my 

best regards,

Markus Hoenicka
AQ score 38

Want to link to this message? Use this URL: <>