[Adduser-devel] Bug#561864: adduser sends output to STDOUT even with --quiet, causing debconf to fail on postinst script for snmpd

Jonathan Nieder jrnieder at gmail.com
Thu Nov 10 06:48:34 UTC 2011


Hi,

Dan Wallis wrote:

> From what I can tell, it's adduser sending some output to STDOUT which
> is causing this postinst script to fail. It looks like the --quiet
> flag isn't being respected, and lines 29-33 of
> /usr/share/debconf/confmodule are ineffective, or at least don't seem
> to do what their comments say they should.

I see that this was fixed in sid; thanks!  Now the question is what to
do in stable.

If I understand correctly, the underlying problem still exists in
net-snmp.  snmpd.postinst says:

	. /usr/share/debconf/confmodule
	db_version 2.0

	#DEBHELPER#

which looks pretty innocuous, except that #DEBHELPER# part expands to

	# Automatically added by dh_installinit
	if [ -x "/etc/init.d/snmpd" ]; then
		update-rc.d snmpd defaults >/dev/null
		invoke-rc.d snmpd start || exit $?
	fi
	# End automatically added section

so that if I edit /etc/init.d/snmpd (which is, after all, a conffile)
to include

	echo "hello, snmpd!"

then that text gets passed to debconf.  Yech.

This might be a debconf bug, a debhelper bug, or a net-snmp bug; I'm
not sure which.  It doesn't sound to me like an adduser bug, although
fixing this minor adduser bug worked around it.





More information about the Adduser-devel mailing list