[pkg-ntp-maintainers] Bug#655515: Bug in ntp.postinst
Gerald Turner
gturner at unzane.com
Thu Apr 18 20:26:43 UTC 2013
Hello, I dist-upgraded from squeeze to testing and had the exact problem
described by Martin Eichenberg, however the suggestions provided by
Michael Stapelberg didn't help.
I believe I have found the problem:
# dpkg --configure --pending --debug=2
Setting up ntp (1:4.2.6.p5+dfsg-2) ...
D000002: fork/exec /var/lib/dpkg/info/ntp.postinst ( configure 1:4.2.6.p2+dfsg-1+b1 )
dpkg: error processing ntp (--configure):
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
ntp
# sh -x /var/lib/dpkg/info/ntp.postinst configure 1:4.2.6.p2+dfsg-1+b1
+ set -e
+ dpkg-maintscript-helper supports rm_conffile
dpkg-maintscript-helper: warning: environment variable DPKG_MAINTSCRIPT_NAME missing
dpkg-maintscript-helper: warning: environment variable DPKG_MAINTSCRIPT_PACKAGE missing
+ dpkg-maintscript-helper supports mv_conffile
dpkg-maintscript-helper: warning: environment variable DPKG_MAINTSCRIPT_NAME missing
dpkg-maintscript-helper: warning: environment variable DPKG_MAINTSCRIPT_PACKAGE missing
+ [ configure = configure ]
+ addgroup --system --quiet ntp
# man addgroup
…
EXIT VALUES
…
1 Creating the user or group failed because it was already present
with other UID/GID than specified. The username or groupname was
rejected because of a mismatch with the configured regular
expressions, see adduser.conf(5). Adduser has been aborted by a
signal. Or for many other yet undocumented reasons which are
printed to console then. You may then consider to remove --quiet to
make adduser more verbose.
…
I hacked around the problem by appending ‘|| true’ expressions to the
postinst addgroup/adduser commands.
After poking around other postinst scripts looking for addgroup/user
usage, I see a better way would probably be something like the bind9
package:
getent group bind >/dev/null 2>&1 || addgroup --system bind
getent passwd bind >/dev/null 2>&1 ||
adduser --system --home /var/cache/bind --no-create-home \
--disabled-password --ingroup bind bind
--
Gerald Turner Email: gturner at unzane.com JID: gturner at unzane.com
GPG: 0xFA8CD6D5 21D9 B2E8 7FE7 F19E 5F7D 4D0C 3FA0 810F FA8C D6D5
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/pkg-ntp-maintainers/attachments/20130418/edaf2bec/attachment.pgp>
More information about the pkg-ntp-maintainers
mailing list