pacemaker fails to install/upgrade if the user hacluster already exists and is not a system user.

Bug #580277 reported by Jose Marquez
18
This bug affects 2 people
Affects Status Importance Assigned to Milestone
pacemaker (Ubuntu)
Fix Released
Medium
Unassigned
Precise
Won't Fix
Undecided
Unassigned

Bug Description

Binary package hint: update-manager

Updating Kubuntu Karmic to Lucid; received error saying I could not install pacemaker.

Revision history for this message
Jean-Baptiste Lallement (jibel) wrote :

Thanks for taking the time to report this bug and helping to make Ubuntu better. Could you please add the log files from '/var/log/dist-upgrade/' to this bug report as separate attachments? Thanks in advance.

Changed in update-manager (Ubuntu):
status: New → Incomplete
Revision history for this message
Jose Marquez (ubuntu-hackwater) wrote :
Revision history for this message
Jose Marquez (ubuntu-hackwater) wrote :
Revision history for this message
Jose Marquez (ubuntu-hackwater) wrote :
Revision history for this message
Jose Marquez (ubuntu-hackwater) wrote :
Revision history for this message
Jose Marquez (ubuntu-hackwater) wrote :
Revision history for this message
Jose Marquez (ubuntu-hackwater) wrote :
Revision history for this message
Jose Marquez (ubuntu-hackwater) wrote :
Revision history for this message
Jean-Baptiste Lallement (jibel) wrote :

Thanks for the logs affecting to pacemaker.

The relevant error is
Setting up pacemaker (1.0.8+hg15494-2ubuntu2) ...
addgroup: The group `haclient' already exists as a system group. Exiting.
Warning: The home dir /var/lib/heartbeat you specified already exists.
adduser: The user `hacluster' already exists. Exiting.
dpkg: error processing pacemaker (--configure):
 subprocess installed post-installation script returned error exit status 1

affects: update-manager (Ubuntu) → pacemaker (Ubuntu)
Changed in pacemaker (Ubuntu):
importance: Undecided → Medium
status: Incomplete → Confirmed
summary: - Could not install pacemaker
+ Could not install pacemaker: addgroup: The group `haclient' already
+ exists as a system group. Exiting.
Revision history for this message
Ante Karamatić (ivoks) wrote : Re: Could not install pacemaker: addgroup: The group `haclient' already exists as a system group. Exiting.

That's not the reason why it failed to install. adduser exits with 0 if user already exists. Something else is the cause.

Revision history for this message
Ante Karamatić (ivoks) wrote :

Jose any chance you still have that broken?

Revision history for this message
Jose Marquez (ubuntu-hackwater) wrote :

Hi Ante,

I just tried to install pacemaker again, and it again chokes on the warning:

Selecting previously deselected package libcorosync4.
(Reading database ... 251107 files and directories currently installed.)
Unpacking libcorosync4 (from .../libcorosync4_1.2.0-0ubuntu1_i386.deb) ...
Selecting previously deselected package libesmtp5.
Unpacking libesmtp5 (from .../libesmtp5_1.0.4-4_i386.deb) ...
Selecting previously deselected package pacemaker.
Unpacking pacemaker (from .../pacemaker_1.0.8+hg15494-2ubuntu2_i386.deb) ...
Processing triggers for man-db ...
Setting up libcorosync4 (1.2.0-0ubuntu1) ...

Setting up libesmtp5 (1.0.4-4) ...

Setting up pacemaker (1.0.8+hg15494-2ubuntu2) ...
addgroup: The group `haclient' already exists as a system group. Exiting.
Warning: The home dir /var/lib/heartbeat you specified already exists.
adduser: The user `hacluster' already exists. Exiting.
dpkg: error processing pacemaker (--configure):
 subprocess installed post-installation script returned error exit status 1
Processing triggers for libc-bin ...
ldconfig deferred processing now taking place
Errors were encountered while processing:
 pacemaker
E: Sub-process /usr/bin/dpkg returned an error code (1)
A package failed to install. Trying to recover:
Setting up pacemaker (1.0.8+hg15494-2ubuntu2) ...
addgroup: The group `haclient' already exists as a system group. Exiting.
Warning: The home dir /var/lib/heartbeat you specified already exists.
adduser: The user `hacluster' already exists. Exiting.
dpkg: error processing pacemaker (--configure):
 subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
 pacemaker

Revision history for this message
Jose Marquez (ubuntu-hackwater) wrote :

Possibly of interest: I only received this error when I upgraded my work laptop from Karmic to Lucid. I don't have the option to do a clean install of Lucid on that laptop. However, on my personal laptop, I did do a clean install of Lucid Lynx. That clean install does not attempt to install pacemaker automatically, though it does manage to install successfully if I manually select it.

Revision history for this message
Ante Karamatić (ivoks) wrote : Re: [Ubuntu-ha] [Bug 580277] Re: Could not install pacemaker: addgroup: The group `haclient' already exists as a system group. Exiting.

Could you give me output of:

DPKG_DEBUG="developer" dpkg --configure -a

Thanks

Revision history for this message
Jose Marquez (ubuntu-hackwater) wrote : Re: Could not install pacemaker: addgroup: The group `haclient' already exists as a system group. Exiting.

user@host:~$ sudo DPKG_DEBUG="developer" dpkg --configure -a
Setting up pacemaker (1.0.8+hg15494-2ubuntu2) ...
addgroup: The group `haclient' already exists as a system group. Exiting.
Warning: The home dir /var/lib/heartbeat you specified already exists.
adduser: The user `hacluster' already exists. Exiting.
dpkg: error processing pacemaker (--configure):
 subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
 pacemaker

Revision history for this message
Ante Karamatić (ivoks) wrote : Re: [Ubuntu-ha] [Bug 580277] Re: Could not install pacemaker: addgroup: The group `haclient' already exists as a system group. Exiting.

On 04.08.2010 21:39, Jose Marquez wrote:
> user@host:~$ sudo DPKG_DEBUG="developer" dpkg --configure -a

Oh, sorry.

sudo DEBCONF_DEBUG="developer" dpkg --configure -a

Revision history for this message
Jose Marquez (ubuntu-hackwater) wrote : Re: Could not install pacemaker: addgroup: The group `haclient' already exists as a system group. Exiting.

user@host:~$ sudo DEBCONF_DEBUG="developer" dpkg --configure -a
Setting up pacemaker (1.0.8+hg15494-2ubuntu2) ...
addgroup: The group `haclient' already exists as a system group. Exiting.
Warning: The home dir /var/lib/heartbeat you specified already exists.
adduser: The user `hacluster' already exists. Exiting.
dpkg: error processing pacemaker (--configure):
 subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
 pacemaker

Revision history for this message
Jean-Baptiste Lallement (jibel) wrote :

Jose,

and what is the output of the command:
$ sudo sh -x /var/lib/dpkg/info/pacemaker.postinst configure

Revision history for this message
Jose Marquez (ubuntu-hackwater) wrote :

user@host:~$ sudo sh -x /var/lib/dpkg/info/pacemaker.postinst configure
+ set -e
+ addgroup --system haclient
addgroup: The group `haclient' already exists as a system group. Exiting.
+ adduser --system hacluster --ingroup haclient --home /var/lib/heartbeat
Warning: The home dir /var/lib/heartbeat you specified already exists.
adduser: The user `hacluster' already exists. Exiting.

Revision history for this message
Jean-Baptiste Lallement (jibel) wrote :

That's weird because as Ante said adduser should exit with status 0

What the output of
$ getent passwd hacluster

Revision history for this message
Jose Marquez (ubuntu-hackwater) wrote :

user@host:~$ getent passwd hacluster
hacluster:x:1001:122:Heartbeat System Account:/usr/lib/heartbeat:/bin/false

Revision history for this message
Jean-Baptiste Lallement (jibel) wrote :

adduser exits with status 1 in this situation because the postinst script asks to create a system user but the user already exists as a non system user.

Jose, I don't know the detailed configuration of your system and what the use of the hacluster user on your system, so take my advice for what it is and adapt to your specific system setup.The easiest way to workaround your problem is to change the uid of the user hacluster to something in the range of system's uid (100 to 999 by default). The command is
$ usermod -u NEW_UID hacluster

choose a non existent uid. Then try performing the installation again.

Changed in pacemaker (Ubuntu):
status: Confirmed → Triaged
summary: - Could not install pacemaker: addgroup: The group `haclient' already
- exists as a system group. Exiting.
+ pacemaker fail to install/upgrade is hacluster already exists and is not
+ a system user.
summary: - pacemaker fail to install/upgrade is hacluster already exists and is not
- a system user.
+ pacemaker fails to install/upgrade is hacluster already exists and is
+ not a system user.
summary: - pacemaker fails to install/upgrade is hacluster already exists and is
- not a system user.
+ pacemaker fails to install/upgrade if the user hacluster already exists
+ and is not a system user.
Revision history for this message
Jose Marquez (ubuntu-hackwater) wrote :

That did the trick. Thanks, Jean-Baptiste; I changed user UID to 128, which was not currently being used (after a quick inspection of UIDs in my passwd file) and pacemaker's installation was able to finish.

Revision history for this message
Ante Karamatić (ivoks) wrote : Re: [Ubuntu-ha] [Bug 580277] Re: Could not install pacemaker: addgroup: The group `haclient' already exists as a system group. Exiting.

On 04.08.2010 23:44, Jean-Baptiste Lallement wrote:

> adduser exits with status 1 in this situation because the postinst
> script asks to create a system user but the user already exists as a non
> system user.

That's hilarious. Good catch!

Thank you guys for debugging.

Revision history for this message
Rafael David Tinoco (rafaeldtinoco) wrote :

Thank you for taking the time to report this bug. In an effort to keep an
up-to-date and valid list of bugs to work on, I have reviewed this report
to verify it still requires effort and occurs on an Ubuntu release in
standard support, and it does not.

It is unfortunate that we were unable to resolve this defect, however
there appears to be no further action possible at this time. I am
therefore moving the bug to 'Incomplete'. If you disagree or have
new information, we would be grateful if you could please add a comment
stating why and then change the status of the bug to 'New'.

Changed in pacemaker (Ubuntu):
status: Triaged → Incomplete
Changed in pacemaker (Ubuntu Precise):
status: New → Incomplete
Changed in pacemaker (Ubuntu):
status: Incomplete → Fix Released
Revision history for this message
Steve Langasek (vorlon) wrote :

The Precise Pangolin has reached end of life, so this bug will not be fixed for that release

Changed in pacemaker (Ubuntu Precise):
status: Incomplete → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.