postinst fails if group exists
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Ubuntu Server papercuts |
Fix Released
|
Medium
|
Thierry Carrez | ||
tomcat6 (Ubuntu) |
Fix Released
|
Medium
|
Thierry Carrez | ||
Lucid |
Fix Released
|
Medium
|
Thierry Carrez |
Bug Description
Binary package hint: tomcat6
In cases where the tomcat6 group already exists (eg ldap), the postinst fails due to running addgroup blindly.
Commenting out the addgroup works fine, although that isn't a generic fix.
> addgroup --system "$TOMCAT6_GROUP" --quiet
> if ! id $TOMCAT6_USER > /dev/null 2>&1 ; then
(I had a better bug report with more detail, but the "no referrer" error ate it. Lovely..)
== SRU Report ==
Impact:
If the tomcat6 group already exists, tomcat6 will fail to install correctly.
Development branch fix:
Fix is in maverick as of 6.0.28-2ubuntu1
Minimal patch:
- addgroup --system "$TOMCAT6_GROUP" --quiet
+ if ! getent group "$TOMCAT6_GROUP" > /dev/null 2>&1 ; then
+ addgroup --system "$TOMCAT6_GROUP" --quiet
+ fi
TEST CASE:
$ sudo addgroup tomcat6
$ sudo apt-get install tomcat6
Affected version:
Tomcat fails to install (subprocess installed post-installation script returned error exit status 1)
Fixed version:
Tomcat installs successfully.
Regression potential:
Given the nature of the patch, it is minimal.
Changed in tomcat6 (Ubuntu): | |
importance: | Undecided → Medium |
status: | New → Confirmed |
Changed in server-papercuts: | |
importance: | Undecided → Medium |
status: | New → Confirmed |
Changed in server-papercuts: | |
milestone: | none → maverick-beta |
Changed in server-papercuts: | |
assignee: | nobody → Thierry Carrez (ttx) |
Changed in tomcat6 (Ubuntu): | |
assignee: | nobody → Thierry Carrez (ttx) |
status: | Confirmed → In Progress |
Changed in server-papercuts: | |
status: | Confirmed → In Progress |
Changed in tomcat6 (Ubuntu): | |
status: | Triaged → In Progress |
Changed in server-papercuts: | |
status: | In Progress → Fix Released |
Changed in tomcat6 (Ubuntu Lucid): | |
status: | New → Triaged |
importance: | Undecided → Medium |
description: | updated |
Changed in tomcat6 (Ubuntu Lucid): | |
assignee: | nobody → Thierry Carrez (ttx) |
tags: | added: testcase |
I can't reproduce that.
If the group already exists, "addgroup --system tomcat6 --quiet" returns 0 and the script proceeds.
Could you confirm what the issue is ?