Package: dbconfig-common
Version: 1.8.13
Severity: normal
When there are no configuration files in /etc/dbconfig-common the config
maintainer script suffers an error as it does not check the result of a
shell expansion.
The offending code is lines 199-202 of dpkg/config.
The root cause is that the expansion will return the literal string
"/etc/dbconfig-common/*.conf" if it could not match any actual
configuration files. This string is then passed directly into
dbconfig-generate-include which generates an error as shown below:
Unpacking db-test-sqlite (from db-test-sqlite_2.0_all.deb) ...
Setting up db-test-sqlite (2.0) ...
unable to read input file /etc/dbconfig-common/*.conf
dpkg: error processing db-test-sqlite (--install):
subprocess post-installation script returned error exit status 10
As the script is set -e this causes the installation to fail.
The patch below offers one possible solution to the problem,
alternatively dbconfig common could run 'shopt -s nullglob' to request
bash returns an empty string when the expansion fails.
--- dpkg/config (revision 216)
+++ dpkg/config (working copy)
@@ -197,6 +197,7 @@
# package, and create a list of hosts.
_preconf_list=` (
for f in /etc/dbconfig-common/*.conf; do
+ test -f $f || continue
eval \`dbconfig-generate-include --dbserver=_s
$f | grep -v '^#'\`
[ "$_s" ] && echo $_s
done
Cheers
-- System Information:
Debian Release: testing/unstable
APT prefers unstable
APT policy: (500, 'unstable')
Architecture: amd64 (x86_64)
Shell: /bin/sh linked to /bin/bash
Kernel: Linux 2.6.16-xen
Locale: LANG=en_NZ.UTF-8, LC_CTYPE=en_NZ.UTF-8 (charmap=UTF-8)
Versions of packages dbconfig-common depends on:
ii debconf [debconf-2.0] 1.5.1 Debian configuration management sy
ii pwgen 2.05-1 Automatic Password generation
ii ucf 2.0010 Update Configuration File: preserv
dbconfig-common recommends no packages.
-- debconf information:
dbconfig-common/internal/reconfiguring: false
dbconfig-common/import-oldsettings:
dbconfig-common/dbconfig-upgrade: true
dbconfig-common/passwords-do-not-match:
dbconfig-common/pgsql/authmethod-admin: ident
dbconfig-common/pgsql/revertconf: false
dbconfig-common/install-error: abort
dbconfig-common/remove-error: abort
dbconfig-common/db/dbname: ${pkg}
dbconfig-common/pgsql/no-empty-passwords:
dbconfig-common/mysql/method: unix socket
dbconfig-common/remember-admin-pass: false
dbconfig-common/pgsql/admin-user: postgres
dbconfig-common/mysql/admin-user: root
dbconfig-common/remote/host:
dbconfig-common/pgsql/manualconf:
dbconfig-common/pgsql/changeconf: false
dbconfig-common/remote/newhost:
dbconfig-common/dbconfig-install: true
dbconfig-common/pgsql/method: unix socket
dbconfig-common/pgsql/authmethod-user: ident
dbconfig-common/upgrade-error: abort
dbconfig-common/database-type:
dbconfig-common/dbconfig-remove: true
dbconfig-common/db/app-user:
dbconfig-common/pgsql/no-user-choose-other-method:
dbconfig-common/remote/port:
dbconfig-common/upgrade-backup: true
dbconfig-common/performing_upgrade: false
dbconfig-common/purge: false
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]