Bug 154122 - /bin/cp option "--preserve": wrong documentation and misbehaviour
Summary: /bin/cp option "--preserve": wrong documentation and misbehaviour
Status: RESOLVED FIXED
Alias: None
Product: SUSE LINUX 10.0
Classification: openSUSE
Component: Basesystem (show other bugs)
Version: Final
Hardware: i386 Other
: P5 - None : Major
Target Milestone: SUSE Linux 10.1
Assignee: Andreas Schwab
QA Contact: E-mail List
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-02-28 15:19 UTC by Wolfgang Schludi
Modified: 2006-02-28 17:43 UTC (History)
1 user (show)

See Also:
Found By: Other
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Wolfgang Schludi 2006-02-28 15:19:10 UTC
installed packages:
===================
- coreutils-5.3.0-20.2
- kernel-bigsmp-2.6.13-15.8
- kernel-bigsmp-nongpl-2.6.13-15.8

reproduce (as root):
==========
# cp --force --parents --preserve=all /boot/vmlinuz /tmp; echo $?
cp: cannot lgetfilecon `/boot/vmlinuz': No data available
1
# cp --force --parents --preserve=mode,ownership,timestamps,links /boot/vmlinuz /tmp; echo $?
0
# selinuxenabled;echo $?
1

bug-description:
================
- info/man states that "--preserve=all" is the same as "--preserve=mode,ownership,timestamps,links". The above example shows the opposite. 
- the first command shouldn't fail as root(this is what we did in our backup script)
- coreutils 5.3.0 don't seem to be a official release. At least at http://ftp.gnu.org/pub/gnu/coreutils/ there is no such version. Why do you distribute unofficial versions?

regards,
 schludi
Comment 1 Andreas Schwab 2006-02-28 17:43:06 UTC
Fixed.