View Issue Details
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0005573||CentOS-5||anaconda||public||2012-03-05 15:04||2012-03-08 17:42|
|Target Version||Fixed in Version|
|Summary||0005573: "An error occurred while installing packages" message during upgrade|
|Description||While doing an upgrade from CentOS 5.7 to 5.8 with the installer on the CD, I get a message saying "An error occurred while installing packages. Please examine /root/install.log on your installed system for detailed information".|
This occurs first at the end of the second CD and may occur again at the end of subsequent CDs. The error message may be suppressed for the last CD in the set. The error message seems to be bogus, as there are no errors in install.log and the system seems to get upgraded just fine. However, there are some entries in upgrade.log.syslog which may explain the error message:
<86>Mar 6 09:07:03 useradd: failed adding user `mailnull', data deleted
<86>Mar 6 09:07:03 useradd: failed adding user `smmsp', data deleted
<86>Mar 6 09:07:03 useradd: failed adding user `nscd', data deleted
<86>Mar 6 09:07:20 useradd: failed adding user `sshd', data deleted
<86>Mar 6 09:07:44 useradd: failed adding user `dbus', data deleted
<86>Mar 6 09:08:07 useradd: failed adding user `rpcuser', data deleted
<86>Mar 6 09:11:49 useradd: failed adding user `apache', data deleted
<86>Mar 6 09:12:04 useradd: failed adding user `gdm', data deleted
<86>Mar 6 09:12:15 useradd: failed adding user `ntp', data deleted
These users were already present in CentOS 5.7. It's possible that the installer get confused about useradd's exit value of 9 in cases like this.
This error message does not seem to occur when upgrading 5.7 to 5.8 with a DVD, because only the first DVD is used in 5.7->5.8 upgrades and the installer seems to disregard any errors that show up during the installation of the last CD/DVD in the set.
|Steps To Reproduce||* Install a non-minimal CentOS 5.7 (any arch)|
* Boot with CentOS 5.8 (any arch, use either text or GUI installer)
* Choose to upgrade an existing installation
* Insert CD1 as prompted
* Insert the next CD as prompted
* Notice the error message after the installer has processed the second CD.
* Repeat the previous two steps until all CDs are processed and system is upgraded.
|Tags||No tags attached.|
|Upstream bug https://bugzilla.redhat.com/show_bug.cgi?id=699088 is somewhat related.|
This is a "feature" of useradd. It was introduced in 5.8 when shadow-utils was updated to 4.0.17-20.el5 including shadow-4.0.17-unlock-files.patch ("make useradd delete lock files on failure"). The patch changed a bunch of exit()'s to fail_exit()'s which syslog the silly message that is useradd's idiosyncratic way of saying "something went wrong".
The current upstream shadow-utils appears to behave the same way.
The problem is mitigated in 6.x because many package scriptlets do not call useradd/groupadd when the desired account/group already exists. 5.x packages are more prone to execute it unconditionally.