bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: mv executed incompletely due to insufficient privileges


From: Eric Blake
Subject: Re: mv executed incompletely due to insufficient privileges
Date: Fri, 17 Aug 2007 20:32:26 -0600
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.6) Gecko/20070728 Thunderbird/2.0.0.6 Mnenhy/0.7.5.666

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

According to Elmar Stellnberger on 8/17/2007 1:13 PM:
> package/version: coreutils-5.93-20

Consider upgrading.  The latest stable coreutils is 6.9.

> 
> In this case the privileges suffice for creating a new directory entry
> for the destination file but not for removing the source file.
> Awkwardly the result will depend on whether the target location resides
> on the same mount point or not:
> * same mount point: nothing is done
> * different mount point: file is copied but not deleted
> 
> Generally we expect mv to be atomic by default.

Thanks for the report.  However, but mv is only atomic when you don't
cross mount points (ie. when rename(2) will do the job, rather than a full
blown copy/delete sequence).

> If the --backup switch is stated we may want it to behave like a copy
> and delete in sequence (copied though not deleted).
> Notwithstanding the result should always be the same no matter whether
> source and destination reside on different mount points!

When successful, the end results are the same.  And on failure, as you
discovered, a message is printed telling you why the failure occurred,
even if the reason for failure differs between local and cross-device
moves.  This behavior is all specified by POSIX, so there is no bug here.

- --
Don't work too hard, make some time for fun as well!

Eric Blake             address@hidden
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFGxlo584KuGfSFAYARAoGaAKDHMOrBc35+uLPzpUw5vP2mi355LgCgzPF4
vzteUb4eK9/kDvLqYgTOSSY=
=UGQm
-----END PGP SIGNATURE-----




reply via email to

[Prev in Thread] Current Thread [Next in Thread]