Bug #7707

FileUtils.mv fails to move symlink between filesystems

Added by Martin Pärtel over 1 year ago. Updated about 1 year ago.

Assignee:Nobuyoshi Nakada
Target version:next minor
ruby -v:ruby 1.9.3p362 (2012-12-25 revision 38607) [x86_64-linux] Backport:


FileUtils.mv sometimes fails with a "Errno::ENOENT: No such file or directory - /path/to/symlink" when attempting to move a directory containing a symlink between filesystems. This may be because it moves the destination file before the symlink and then fails to move a "broken" symlink. Using the shell's "mv" instead works reliably.

A small test script is attached.

test.rb Magnifier - Test script (requires bindfs and linux but easy enough to modify) (627 Bytes) Martin Pärtel, 01/17/2013 04:05 AM


#1 Updated by Koichi Sasada about 1 year ago

  • Assignee set to Nobuyoshi Nakada
  • Target version changed from 1.9.3 to next minor

Also available in: Atom PDF