Announcement

Collapse
No announcement yet.

apt-get problems

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    apt-get problems

    Hi, I'm having some problem with apt-get, whenever I try to install something using apt-get install I get this error message:

    (Reading database ... 75947 files and directories currently installed.)
    Preparing to replace postgresql-8.1 8.1.4-0ubuntu1 (using postgresql-8.1_8.1.4-0ubuntu1_i386.deb) ...
    * Stopping PostgreSQL 8.1 database server * Error: specified cluster does not exist
    [fail]
    invoke-rc.d: initscript postgresql-8.1, action "stop" failed.
    dpkg: warning - old pre-removal script returned error exit status 1
    dpkg - trying script from the new package instead ...
    * Stopping PostgreSQL 8.1 database server * Error: specified cluster does not exist
    [fail]
    invoke-rc.d: initscript postgresql-8.1, action "stop" failed.
    dpkg: error processing postgresql-8.1_8.1.4-0ubuntu1_i386.deb (--install):
    subprocess new pre-removal script returned error exit status 1
    * Starting PostgreSQL 8.1 database server * Error: specified cluster does not exist
    [fail]
    invoke-rc.d: initscript postgresql-8.1, action "start" failed.
    dpkg: error while cleaning up:
    subprocess post-installation script returned error exit status 1
    Errors were encountered while processing:
    postgresql-8.1_8.1.4-0ubuntu1_i386.deb

    When I try to remove it I get this error message:

    Reading package lists... Done
    Building dependency tree... Done
    The following packages will be REMOVED:
    postgresql-8.1
    0 upgraded, 0 newly installed, 1 to remove and 35 not upgraded.
    14 not fully installed or removed.
    Need to get 0B of archives.
    After unpacking 12.9MB disk space will be freed.
    Do you want to continue [Y/n]? y
    dpkg: error processing postgresql-8.1 (--remove):
    Package is in a very bad inconsistent state - you should
    reinstall it before attempting a removal.
    terminate called after throwing an instance of 'std::logic_error'
    what(): basic_string::_S_construct NULL not valid
    Aborted
    root@felipe-desktop:~# Errors were encountered while processing:
    postgresql-8.1


    The package installation goes well, but postgresql is not working, and I can't remove it and install it again because it displays the same message.

    How can I make it work, or how can I re-install it?

    PS: When I was looking for the java-sun package I included some ubuntu repositories.

    Thanks,
    Komyg

    #2
    Re: apt-get problems

    Try:
    Code:
    sudo apt-get install --reinstall postgresql-8.1
    sudo apt-get remove postgresql-8.1
    Let us know if that works.

    Comment


      #3
      Re: apt-get problems

      I'm sorry but I've already tryed this commands and they don't work.
      But I filed a bug report on this and the answer worked just fine. I'm posting here the commands that I used:

      sudo apt-get install postgresql-common postgresql-client-common postgresql-8.1
      sudo dpkg -P postgresql-8.1 postgresql-client-8.1

      after this it's just:

      sudo apt-get remove postgresql-8.1
      sudo apt-get install postgresql-8.1

      Thank you for your help,
      Komyg

      Comment

      Working...
      X