GNU bug report logs - #34713
Files vanishing when moving to different FS

Previous Next

Package: coreutils;

Reported by: Christoph Michelbach <michelbach94 <at> gmail.com>

Date: Sat, 2 Mar 2019 22:12:02 UTC

Severity: normal

Tags: notabug

Done: Bob Proulx <bob <at> proulx.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Christoph Michelbach <michelbach94 <at> gmail.com>
To: Bob Proulx <bob <at> proulx.com>
Cc: 34713 <at> debbugs.gnu.org
Subject: bug#34713: Files vanishing when moving to different FS
Date: Mon, 4 Mar 2019 20:57:45 +0100
Hello, Bob

Thank you for your explanation. I understand what's going on and even 
looked at the part of the source code that causes the problem prior to 
filing the bug report.


Even if you don't consider it a bug, it's still unexpected behavior that 
could be avoided. I think that mv's behavior would be more logical if it 
only removed files that it copied prior to removal (simple solution to 
the problem without destroying user data) or also move files that 
appeared in the destination location during the copying process 
(emulating moving a directory within a file system better and not 
destroying user data).


In the first case, it should still try to remove directories after 
removing all files in them but adhere to the rule that non-empty 
directories cannot be deleted instead of simply emptying them of their 
content prior to deletion.


In the second case, it should attempt to delete the directory and if 
this fails because it is non-empty, copy the newly appeared files over 
to the destination.


I think that the second solution is better for the users as it emulates 
the behavior of a move operation within a file system. However, I see 
that the first solution is easier to implement. The current behavior of 
mv destroys user data which I think is highly unexpected behavior.


Christoph





This bug report was last modified 6 years and 135 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.