Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
For bugs related to Red Hat Enterprise Linux 5 product line. The current stable release is 5.10. For Red Hat Enterprise Linux 6 and above, please visit Red Hat JIRA https://issues.redhat.com/secure/CreateIssue!default.jspa?pid=12332745 to report new issues.

Bug 627285

Summary: mv --backup does not work for directories
Product: Red Hat Enterprise Linux 5 Reporter: Kamil Dudka <kdudka>
Component: coreutilsAssignee: Ondrej Vasik <ovasik>
Status: CLOSED ERRATA QA Contact: qe-baseos-daemons
Severity: low Docs Contact:
Priority: low    
Version: 5.4CC: asersen, azelinka
Target Milestone: rc   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: coreutils-5.97-28.el5 Doc Type: Bug Fix
Doc Text:
Previously, the "--backup" option of the mv command did not work with directories and the "cannot move [directory] to a subdirectory of itself" error message was given. This bug has been fixed and the "--backup" option now works with directories as expected.
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-07-21 10:36:56 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Kamil Dudka 2010-08-25 14:53:09 UTC
Version-Release number of selected component (if applicable):
coreutils-5.97-23.el5


How reproducible:
100%


Steps to Reproduce:
1. mkdir -p src/dir dst/dir
2. touch src/dir/file dst/dir/file
3. mv -v --backup=numbered src/dir dst

  
Actual results:
mv: cannot move `src/dir' to a subdirectory of itself, `dst/dir'


Expected results:
`src/dir' -> `dst/dir' (backup: `dst/dir.~1~')


Additional info:
works fine in RHEL-6 and Fedora

Comment 1 RHEL Program Management 2011-01-11 20:14:40 UTC
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated in the
current release, Red Hat is unfortunately unable to address this
request at this time. Red Hat invites you to ask your support
representative to propose this request, if appropriate and relevant,
in the next release of Red Hat Enterprise Linux.

Comment 2 RHEL Program Management 2011-01-11 22:23:32 UTC
This request was erroneously denied for the current release of
Red Hat Enterprise Linux.  The error has been fixed and this
request has been re-proposed for the current release.

Comment 9 Tomas Capek 2011-07-13 12:14:06 UTC
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
Previously, the "--backup" option of the mv command did not work with directories and the "cannot move [directory] to a subdirectory of itself" error message was given. This bug has been fixed and the "--backup" option now works with directories as expected.

Comment 10 errata-xmlrpc 2011-07-21 10:36:56 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2011-1074.html

Comment 11 errata-xmlrpc 2011-07-21 12:18:34 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2011-1074.html