[Pkg-postgresql-public] Bug#697291: postgresql-common: PGCLUSTER env var conflicts with PGHOST and select wrong database version
Rodrigo Rosenfeld Rosas
rr_rosas at yahoo.com.br
Thu Jan 3 16:10:08 UTC 2013
Package: postgresql-common
Version: 138
Severity: critical
Tags: upstream
Justification: causes serious data loss
* What led up to the situation?
Set both PGHOST and PGCLUSTER.
* What exactly did you do (or not do) that was effective (or
ineffective)?
"psql -l" should use the cluster set on PGCLUSTER to list the databases
for that cluster. Instead it ignores the value of PGCLUSTER. If I unset
PGHOST and use "psql -h localhost -l" instead, then it works. Also, if I
use "psql --cluster 9.1/main" than it also works.
Otherwise "psql -l" will list the databases from 9.2/main even though
PGCLUSTER is set to 9.1/main. This is a big problem if you do something
like "dropdb dbname_from_old_cluster" and the same name happens to exist
in the new cluster, so that you'll drop the wrong database.
-- System Information:
Debian Release: 7.0
APT prefers unstable
APT policy: (700, 'unstable'), (650, 'experimental'), (500, 'stable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386
Kernel: Linux 3.5-trunk-amd64 (SMP w/6 CPU cores)
Locale: LANG=pt_BR.UTF-8, LC_CTYPE=pt_BR.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Versions of packages postgresql-common depends on:
ii adduser 3.113+nmu3
ii debconf [debconf-2.0] 1.5.49
ii logrotate 3.8.3-3
ii lsb-base 4.1+Debian9
ii postgresql-client-common 138
ii procps 1:3.3.4-2
ii ssl-cert 1.0.32
postgresql-common recommends no packages.
postgresql-common suggests no packages.
-- Configuration Files:
/etc/sysctl.d/30-postgresql-shm.conf changed:
kernel.shmmax = 147841024
kernel.shmall = 2097152
-- debconf information:
postgresql-common/obsolete-major:
More information about the Pkg-postgresql-public
mailing list