Red Hat Bugzilla – Bug 632444
'install' gives bad state when 'strip' fails
Last modified: 2013-08-15 10:40:20 EDT
Description of problem: If the command is "install -s -m 755 SOURCE DEST" and 'strip' cannot be found, then 'install' neither fails nor succeeds. It gives an error message on stderr about 'strip', then quits without applying the "-m 755". The result is partially correct (the file is copied to the destination and not stripped), but the destination file still has the default mode for a new file. This is truly bad because usually the default mode is 0600, which is not executable. Instead, the remaining options should be processed [if possible] before terminating.
Version-Release number of selected component (if applicable):
How reproducible: every time
Steps to Reproduce:
1. rm -f /usr/bin/strip
2. cp /bin/date /tmp/foo; chmod 600 /tmp/foo
2. install -s -m 755 /tmp/foo /usr/bin
3. ls -l /usr/bin/foo
install: cannot run strip: No such file or directory
install: strip process terminated abnormally
-rw-------. 1 root root 60632 Sep 9 16:08 /usr/bin/foo
-rwxr-xr-x. 1 root root 60632 Sep 9 16:08 /usr/bin/foo
Thanks for report (and sorry for delay) ...
I see two options:
1) checking for strip program availability when the option is chosen (if not, then it should either fail or disable strip option with information message )
2) making strip, preserve timestamps and attributes change failures non-terminal (just set exit code to install failure)
Resolved upstream by http://git.sv.gnu.org/cgit/coreutils.git/commit/?id=3a20f688 . Thanks Ondrej for working on this old issue.
This bug appears to have been reported against 'rawhide' during the Fedora 19 development cycle.
Changing version to '19'.
(As we did not run this process for some time, it could affect also pre-Fedora 19 development
cycle bugs. We are very sorry. It will help us with cleanup during Fedora 19 End Of Life. Thank you.)
More information and reason for this action is here:
This one was already resolved by coreutils-8.21-6.fc19, so closing RAWHIDE.