[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

apt-get upgrade trouble (with postgresql-client-7.4)



Short version -- we've got an APT-GET/DPKG blocker mystery and need
some help in fixing it:
"""
Starting PostgreSQL 7.4 database server:
main/usr/lib/postgresql/7.4/bin/pg_controldata: error while loading
shared libraries: libpq.so.3: cannot open shared object file: No such
file or directory
Error: Could not parse locale out of pg_controldata output
"""

Meaning, pg_controldata won't run because it can't find libpq.so.3?

Where would libpq.so disappear to? Or, more appropriately, how to fix
this? We'd like to remove 7.4 as we're using 8.1 now... Any pointers
would be appreciated.

===

Long version (here's what we've tried):

In trying to upgrade all packages on our debian server
(/etc/debian_version = '4.0') after apt-get update... postgresql-7.4
is broken -- can't start it, can't remove it, can't reinstall it:

# apt-get upgrade
Reading package lists... Done
Building dependency tree... Done
You might want to run 'apt-get -f install' to correct these.
The following packages have unmet dependencies.
  postgresql-7.4: Depends: postgresql-client-7.4 but it is not installable
E: Unmet dependencies. Try using -f.

# apt-get -f install
Reading package lists... Done
Building dependency tree... Done
Correcting dependencies...Done
The following packages will be REMOVED
  postgresql-7.4
0 upgraded, 0 newly installed, 1 to remove and 443 not upgraded.
1 not fully installed or removed.
Need to get 0B of archives.
After unpacking 8397kB disk space will be freed.
Do you want to continue [Y/n]?
(Reading database ... 42030 files and directories currently installed.)
Removing postgresql-7.4 ...
Stopping PostgreSQL 7.4 database server: mainError: pid file is
invalid, please manually kill the stale server process.
 failed!
invoke-rc.d: initscript postgresql-7.4, action "stop" failed.
dpkg: error processing postgresql-7.4 (--remove):
 subprocess pre-removal script returned error exit status 1
Starting PostgreSQL 7.4 database server:
main/usr/lib/postgresql/7.4/bin/pg_controldata: error while loading
shared libraries: libpq.so.3: cannot open shared object file: No such
file or directory
Error: Could not parse locale out of pg_controldata output
 failed!
invoke-rc.d: initscript postgresql-7.4, action "start" failed.
dpkg: error while cleaning up:
 subprocess post-installation script returned error exit status 1
Errors were encountered while processing:
 postgresql-7.4
E: Sub-process /usr/bin/dpkg returned an error code (1)

# apt-get --purge remove postgresql-client-7.4
Reading package lists... Done
Building dependency tree... Done
Package postgresql-client-7.4 is not installed, so not removed
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies.
  postgresql-7.4: Depends: postgresql-client-7.4 but it is not installable
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or
specify a solution).


Looking for specific symptoms:

# /etc/init.d/postgresql-7.4 stop
Stopping PostgreSQL 7.4 database server: mainError: pid file is
invalid, please manually kill the stale server process.
 failed!

# /etc/init.d/postgresql-7.4 start
Starting PostgreSQL 7.4 database server:
main/usr/lib/postgresql/7.4/bin/pg_controldata: error while loading
shared libraries: libpq.so.3: cannot open shared object file: No such
file or directory
Error: Could not parse locale out of pg_controldata output
 failed!

# dpkg --configure -a
<no output>


Sometimes aptitude pulls a rabbit out of its hat, but not here:

Errors were encountered while processing:
 postgresql-7.4
E: Sub-process /usr/bin/dpkg returned an error code (1)
A package failed to install.  Trying to recover:
Press return to continue.


Argh! Any help would be gratefully appreciated. Thanks!


-- 
will trillich -- http://faq.serensoft.com/
With a burning "yes" around your high priorities you can easily say
"no" to things that are urgent but not important. -- S. Covey


Reply to: