Package: dbconfig-common Version: 1.8.13 Severity: normal Hey Sean,
I know that this issue was raised in other reports, but I wanted a bug
just about this issue, since it is fairly straight forward to fix and is
less broad than the other 'is broken' reports.
So the problem is mainly the chown call. Just wrapping that in an
if `id dbuser` call would do the trick, but is rather simplistic, of
course.
I think the correct approach is to first add the user to postgresql as
the postgres superuser. Then try to connect to the database as that user.
If that succeeds, then either the package has done the correct thing and
added the user already, or postgres has been configured to use passwords,
and we don't need to care.
The only thing we need to do then is check if id $user returns
something, and if so, chown and su - $user, else continue and just use
-U $user.
Hope that's helpful - if you want specific patches, let me know and I'll
take a look at things. Right now, I've only managed to find the chown
call, so pointers would be nice.
Take care,
-- System Information:
Debian Release: testing/unstable
APT prefers unstable
APT policy: (500, 'unstable')
Architecture: i386 (i686)
Shell: /bin/sh linked to /bin/bash
Kernel: Linux 2.6.16-1-686-smp
Locale: LANG=en_US.UTF8, LC_CTYPE=en_US.UTF8 (charmap=UTF-8) (ignored: LC_ALL
set to en_US.UTF8)
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/import-oldsettings:
dbconfig-common/pgsql/revertconf: false
dbconfig-common/db/dbname: ${pkg}
dbconfig-common/pgsql/manualconf:
dbconfig-common/dbconfig-remove: true
dbconfig-common/mysql/method: unix socket
dbconfig-common/upgrade-backup: true
dbconfig-common/performing_upgrade: false
dbconfig-common/pgsql/authmethod-admin: ident
dbconfig-common/upgrade-error: abort
dbconfig-common/purge: false
dbconfig-common/install-error: abort
dbconfig-common/pgsql/no-empty-passwords:
dbconfig-common/pgsql/admin-user: postgres
dbconfig-common/dbconfig-install: true
dbconfig-common/remote/host:
dbconfig-common/pgsql/changeconf: false
dbconfig-common/remote/newhost:
dbconfig-common/dbconfig-upgrade: true
dbconfig-common/pgsql/no-user-choose-other-method:
dbconfig-common/internal/reconfiguring: false
dbconfig-common/passwords-do-not-match:
dbconfig-common/remove-error: abort
* dbconfig-common/remember-admin-pass: false
dbconfig-common/mysql/admin-user: root
dbconfig-common/pgsql/method: unix socket
dbconfig-common/pgsql/authmethod-user: ident
dbconfig-common/database-type:
dbconfig-common/db/app-user:
dbconfig-common/remote/port:
--
-----------------------------------------------------------------
| ,''`. Stephen Gran |
| : :' : [EMAIL PROTECTED] |
| `. `' Debian user, admin, and developer |
| `- http://www.debian.org |
-----------------------------------------------------------------
signature.asc
Description: Digital signature

