Installing zabbix-frontend-php fails in noninteractive mode

Bug #800543 reported by Tom Ellis
12
This bug affects 1 person
Affects Status Importance Assigned to Milestone
dbconfig-common (Debian)
Fix Released
Unknown
dbconfig-common (Ubuntu)
Fix Released
Medium
Unassigned
Lucid
Won't Fix
Medium
Unassigned

Bug Description

## Issue

* When installing zabbix-frontend-php in noninteractive mode the install fails to determine the database type

## Environment

* Ubuntu 10.04 LTS (Lucid) x86_64

* zabbix-frontend-php & zabbix-server-mysql 1:1.8.1-1ubuntu1

* Using preseeding and Puppet (which uses apt in noninteractive mode, DEBIAN_FRONTEND=noninteractive)

## Diagnostic Steps

1. Install Ubuntu 10.04 LTS

2. Install mysql-server

3. Preseed the zabbix-frontend-php & zabbix-server-mysql packages

4. Install the zabbix packages via puppet or 'sudo DEBIAN_FRONTEND=noninteractive apt-get install zabbix-server-mysql zabbix-frontend-php'

5. See the installation fail:

Setting up zabbix-frontend-php (1:1.8.1-1ubuntu1) ...
sanity check failed for dbc_dbtype.
error encountered :
dbconfig-common can not determine the database type.
dbconfig-common: zabbix-frontend-php configure: aborted.
dbconfig-common: flushing administrative password
dpkg: error processing zabbix-frontend-php (--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:
 zabbix-frontend-php
E: Sub-process /usr/bin/dpkg returned an error code (1)

## Additional Information

The installation uses dbconfig-common (dbconfig-common_1.8.44 in Lucid) which fails much more gracefully when using Maverick (dbconfig-common_1.8.46)

This was also mentioned on Puppet-users some time ago:
http://groups.google.com/group/puppet-users/browse_thread/thread/205119dd8336edd9?tvc=2&fwc=1

Regression potential should be considered low. The patch has been cherry picked from a later version, and has been out in the wild for a while.

Revision history for this message
Tom Ellis (tellis) wrote :

I am preseeding the following using debconf-set-selections before installing the packages:

mysql-server-5.1 mysql-server/root_password_again password root
mysql-server-5.1 mysql-server/root_password password root
zabbix-server-mysql zabbix-server-mysql/dbconfig-install boolean true
zabbix-server-mysql zabbix-server-mysql/database-type select mysql
zabbix-server-mysql zabbix-server-mysql/mysql/app-pass password zabbix
zabbix-server-mysql zabbix-server-mysql/app-password-confirm password zabbix
zabbix-server-mysql zabbix-server-mysql/mysql/admin-pass password root
zabbix-server-mysql zabbix-server-mysql/password-confirm password root
zabbix-frontend-php zabbix-frontend-php/mysql/app-pass password zabbix
zabbix-frontend-php zabbix-frontend-php/pgsql/app-pass password zabbix
zabbix-frontend-php zabbix-frontend-php/database-type select mysql
zabbix-frontend-php zabbix-frontend-php/password-confirm password root
zabbix-frontend-php zabbix-frontend-php/mysql/admin-pass password root
zabbix-frontend-php zabbix-frontend-php/app-password-confirm password zabbix
zabbix-frontend-php zabbix-frontend-php/pgsql/admin-pass password
zabbix-frontend-php zabbix-frontend-php/mysql/admin-user string root

description: updated
Revision history for this message
Tom Ellis (tellis) wrote :

Actually, this is a dbconfig issue

affects: zabbix (Ubuntu) → dbconfig-common (Ubuntu)
Revision history for this message
Tom Ellis (tellis) wrote :

Looks like this actually a dbconfig issue, I added the package from Maverick (dbconfig-common_1.8.46) and it seems to be fixed.

I'll work out which patch fixed it and perhaps we can get it into an update for Lucid.

Revision history for this message
Dave Walker (davewalker) wrote :

@Tom, thanks for your detailed report and looking into it. I think i have found the Debian bug where this was discussed and resolved. I've added the Debian bug, and marked this Fix Released, and opened a task for Lucid.

Thanks!

Next step, A minimal patch needs to be created based on the pure fix for this issue.

Changed in dbconfig-common (Ubuntu):
status: New → Fix Released
status: Fix Released → New
status: New → Fix Released
Changed in dbconfig-common (Ubuntu Lucid):
status: New → Confirmed
importance: Undecided → Medium
Changed in dbconfig-common (Ubuntu):
importance: Undecided → Medium
Revision history for this message
Tom Ellis (tellis) wrote :

Hi Daviey, Thanks for the tips.

I just tested the fix in the bug you linked but it doesn't work, but the fix from debbug http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=542381 does. Relinking to that one.

Revision history for this message
Tom Ellis (tellis) wrote :

I pulled the patch from the upstream bug:
http://anonscm.debian.org/gitweb/?p=dbconfig-common/dbconfig-common.git;a=commitdiff_plain;h=3a94f160d74f03296652fccdb8ea12beecd525fa

I've created a debdiff and tested it and this resolves the problem for me.

@Daviey: Debdiff is attached, can you please sponsor it for Lucid for me?

Thanks!

Revision history for this message
Tom Ellis (tellis) wrote :

Bah, actually, hold on, my builds of this show otherwise now....

Revision history for this message
Tom Ellis (tellis) wrote :

So, I've retested this and used git bisect to locate the right patch and I'm back on the one I mentioned before.
I'm certain this fixes the issue now, retested multiple times in a clean environment.

Revision history for this message
Tom Ellis (tellis) wrote :

@Daviey - I also had a customer confirm the fix with a test package built using that debdiff

Revision history for this message
Dave Walker (davewalker) wrote :

Uploaded to lucid-proposed, currently in the Unapproved queue awaiting SRU processing. Thanks Tom!

description: updated
description: updated
Revision history for this message
Martin Pitt (pitti) wrote :

Uploaded. Subscribing ubuntu-sru for review, unsubscribing sponsors.

Changed in dbconfig-common (Ubuntu Lucid):
status: Confirmed → In Progress
Revision history for this message
Martin Pitt (pitti) wrote : Please test proposed package

Hello Tom, or anyone else affected,

Accepted dbconfig-common into lucid-proposed, the package will build now and be available in a few hours. Please test and give feedback here. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you in advance!

Changed in dbconfig-common (Ubuntu Lucid):
status: In Progress → Fix Committed
tags: added: verification-needed
Changed in dbconfig-common (Debian):
status: Unknown → Fix Released
Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote : Verification still needed

The fix for the this bug has been awaiting testing feedback in the -proposed repository for lucid for more than 90 days. Please test this fix and update the bug appropriately with the results. In the event that the fix for this bug is still not verified 15 days from now the package will be removed from the -proposed repository.

tags: added: removal-candidate
Revision history for this message
Brian Murray (brian-murray) wrote :

The version of dbconfig-common in lucid-proposed has been removed as this bug report was not verified in a timely fashion.

tags: removed: verification-needed
tags: removed: removal-candidate
Changed in dbconfig-common (Ubuntu Lucid):
status: Fix Committed → Triaged
Revision history for this message
Rolf Leggewie (r0lf) wrote :

lucid has seen the end of its life and is no longer receiving any updates. Marking the lucid task for this ticket as "Won't Fix".

Changed in dbconfig-common (Ubuntu Lucid):
status: Triaged → 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.