Michael Biebl wrote:
> Holger Levsen wrote:
> > Package: rsyslog-mysql
> > Version: 4.2.0-1
> > Severity: serious
> > User: debian...@lists.debian.org
> > Usertags: piuparts piuparts.d.o
> >
> > Hi,
> >
> > during a test with piuparts I noticed your package failed to install.
> >
> > From the attached log (scroll to the bottom...):
> >
> >   Setting up rsyslog-mysql (4.2.0-1) ...
> >   dbconfig-common: writing config to
> > /etc/dbconfig-common/rsyslog-mysql.conf
> >
> >   Creating config file /etc/dbconfig-common/rsyslog-mysql.conf with new
> > version
> >
> >   Creating config file /etc/rsyslog.d/mysql.conf with new version
> >   warning: database package not installed?
> >   dbconfig-common: rsyslog-mysql configure: aborted.
> >   dbconfig-common: flushing administrative password
> >   dpkg: error processing rsyslog-mysql (--configure):
> >    subprocess installed post-installation script returned error exit
> > status 1 Errors were encountered while processing:
> >    rsyslog-mysql
> >   E: Sub-process /usr/bin/dpkg returned an error code (1)
>
> Afaics I'm using dbconfig-common as documented, so this issue should imho
> be handled there.

One thing you're not doing is "Recommends: mysql-client". But I doubt that 
would have helped here.

> I'll leave it to Sean to decide, how dbconfig-common should behave in a
> non-interactive mode (which I guess was used in the piuparts test)

If someone installs a dbconfig-common-using package in non-interactive mode 
and doesn't supply any explicit preseeding, then I think we can assume that 
they want to answer "no" to "Configure database for ${pkg} with 
dbconfig-common?"

The attached (currently untested) patch could be a solution to this.


cheers,
Thijs
--- dpkg/config.orig	2010-01-06 11:16:07.344467011 +0100
+++ dpkg/config	2010-01-06 11:16:10.320693083 +0100
@@ -103,7 +103,7 @@
 	#         - multidb support step 1
 	2)
 		db_get $install_question
-		if [ "$RET" != "true" ]; then
+		if [ "$DEBIAN_FRONTEND" = "noninteractive" || "$RET" != "true" ]; then
 			db_set $dbc_package/internal/skip-preseed true
 			return 0;
 		fi

Attachment: signature.asc
Description: This is a digitally signed message part.

Reply via email to