Results 1 to 2 of 2

Thread: 11.10 MySQL install errors, doesn't work, cant uninstall either!

  1. #1
    Join Date
    Aug 2011
    Beans
    7

    11.10 MySQL install errors, doesn't work, cant uninstall either!

    Googled for this over the past few days, no idea whats going wrong. MySQL installation fails:


    Code:
    s3user@s3m1:~$ sudo apt-get install mysql
    [sudo] password for s3user: 
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    E: Unable to locate package mysql
    s3user@s3m1:~$ sudo apt-get install mysql-server
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    The following extra packages will be installed:
      libdbd-mysql-perl libdbi-perl libhtml-template-perl libnet-daemon-perl
      libplrpc-perl mysql-client-5.1 mysql-client-core-5.1 mysql-server-5.1
      mysql-server-core-5.1
    Suggested packages:
      libipc-sharedcache-perl libterm-readkey-perl tinyca mailx
    The following NEW packages will be installed:
      libdbd-mysql-perl libdbi-perl libhtml-template-perl libnet-daemon-perl
      libplrpc-perl mysql-client-5.1 mysql-client-core-5.1 mysql-server
      mysql-server-5.1 mysql-server-core-5.1
    0 upgraded, 10 newly installed, 0 to remove and 19 not upgraded.
    Need to get 21.9 MB of archives.
    After this operation, 56.6 MB of additional disk space will be used.
    Do you want to continue [Y/n]? Y
    Get:1 http://us.archive.ubuntu.com/ubuntu/ oneiric/main libnet-daemon-perl all 0.48-1 [43.1 kB]
    Get:2 http://us.archive.ubuntu.com/ubuntu/ oneiric/main libplrpc-perl all 0.2020-2 [36.0 kB]
    Get:3 http://us.archive.ubuntu.com/ubuntu/ oneiric/main libdbi-perl amd64 1.616-1build1 [853 kB]
    Get:4 http://us.archive.ubuntu.com/ubuntu/ oneiric/main libdbd-mysql-perl amd64 4.019-1 [110 kB]
    Get:5 http://us.archive.ubuntu.com/ubuntu/ oneiric/main mysql-client-core-5.1 amd64 5.1.58-1ubuntu1 [99.7 kB]
    Get:6 http://us.archive.ubuntu.com/ubuntu/ oneiric/main mysql-client-5.1 amd64 5.1.58-1ubuntu1 [9,354 kB]
    Get:7 http://us.archive.ubuntu.com/ubuntu/ oneiric/main mysql-server-core-5.1 amd64 5.1.58-1ubuntu1 [4,976 kB]
    Get:8 http://us.archive.ubuntu.com/ubuntu/ oneiric/main mysql-server-5.1 amd64 5.1.58-1ubuntu1 [6,387 kB]
    Get:9 http://us.archive.ubuntu.com/ubuntu/ oneiric/main libhtml-template-perl all 2.10-1 [65.0 kB]
    Get:10 http://us.archive.ubuntu.com/ubuntu/ oneiric/main mysql-server all 5.1.58-1ubuntu1 [6,302 B]
    Fetched 21.9 MB in 1min 2s (350 kB/s)                                          
    Preconfiguring packages ...
    Selecting previously deselected package libnet-daemon-perl.
    (Reading database ... 190780 files and directories currently installed.)
    Unpacking libnet-daemon-perl (from .../libnet-daemon-perl_0.48-1_all.deb) ...
    Selecting previously deselected package libplrpc-perl.
    Unpacking libplrpc-perl (from .../libplrpc-perl_0.2020-2_all.deb) ...
    Selecting previously deselected package libdbi-perl.
    Unpacking libdbi-perl (from .../libdbi-perl_1.616-1build1_amd64.deb) ...
    Selecting previously deselected package libdbd-mysql-perl.
    Unpacking libdbd-mysql-perl (from .../libdbd-mysql-perl_4.019-1_amd64.deb) ...
    Selecting previously deselected package mysql-client-core-5.1.
    Unpacking mysql-client-core-5.1 (from .../mysql-client-core-5.1_5.1.58-1ubuntu1_amd64.deb) ...
    Selecting previously deselected package mysql-client-5.1.
    Unpacking mysql-client-5.1 (from .../mysql-client-5.1_5.1.58-1ubuntu1_amd64.deb) ...
    Selecting previously deselected package mysql-server-core-5.1.
    Unpacking mysql-server-core-5.1 (from .../mysql-server-core-5.1_5.1.58-1ubuntu1_amd64.deb) ...
    Selecting previously deselected package mysql-server-5.1.
    Unpacking mysql-server-5.1 (from .../mysql-server-5.1_5.1.58-1ubuntu1_amd64.deb) ...
     * MySQL server PID file could not be found!
    Obsolete conffile /etc/init.d/mysql has been modified by you, renaming to .dpkg-bak
    Selecting previously deselected package libhtml-template-perl.
    Unpacking libhtml-template-perl (from .../libhtml-template-perl_2.10-1_all.deb) ...
    Selecting previously deselected package mysql-server.
    Unpacking mysql-server (from .../mysql-server_5.1.58-1ubuntu1_all.deb) ...
    Processing triggers for man-db ...
    Processing triggers for ureadahead ...
    ureadahead will be reprofiled on next reboot
    Setting up libnet-daemon-perl (0.48-1) ...
    Setting up libplrpc-perl (0.2020-2) ...
    Setting up libdbi-perl (1.616-1build1) ...
    Setting up libdbd-mysql-perl (4.019-1) ...
    Setting up mysql-client-core-5.1 (5.1.58-1ubuntu1) ...
    Setting up mysql-client-5.1 (5.1.58-1ubuntu1) ...
    Setting up mysql-server-core-5.1 (5.1.58-1ubuntu1) ...
    Setting up mysql-server-5.1 (5.1.58-1ubuntu1) ...
    111207 14:33:08 [Note] Plugin 'FEDERATED' is disabled.
    111207 14:33:08  InnoDB: Initializing buffer pool, size = 8.0M
    111207 14:33:08  InnoDB: Completed initialization of buffer pool
    111207 14:33:09  InnoDB: Started; log sequence number 0 1595675
    111207 14:33:09  InnoDB: Starting shutdown...
    111207 14:33:14  InnoDB: Shutdown completed; log sequence number 0 1595675
    start: Job failed to start
    invoke-rc.d: initscript mysql, action "start" failed.
    dpkg: error processing mysql-server-5.1 (--configure):
     subprocess installed post-installation script returned error exit status 1
    Setting up libhtml-template-perl (2.10-1) ...
    dpkg: dependency problems prevent configuration of mysql-server:
     mysql-server depends on mysql-server-5.1; however:
      Package mysql-server-5.1 is not configured yet.
    dpkg: error processing mysql-server (--configure):
     dependency problems - leaving unconfigured
    No apport report written because the error message indicates its a followup error from a previous failure.
                              Errors were encountered while processing:
     mysql-server-5.1
     mysql-server
    E: Sub-process /usr/bin/dpkg returned an error code (1)
    This is what happens when I try to use MySQL:

    Code:
    s3user@s3m1:~$ mysql -h localhost -u root -p
    Enter password: 
    ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)
    Common fix for this is to restart MySQL. I do this, but it fails to start:

    Code:
    s3user@s3m1:/var/run/mysqld$ sudo /etc/init.d/mysql restart
    Rather than invoking init scripts through /etc/init.d, use the service(8)
    utility, e.g. service mysql restart
    
    Since the script you are attempting to invoke has been converted to an
    Upstart job, you may also use the stop(8) and then start(8) utilities,
    e.g. stop mysql ; start mysql. The restart(8) utility is also available.
    start: Job failed to start
    At this point, I decide to uninstall MySQL. For some strange reason, it doesn't uninstall at all. MySQL seems to get REINSTALLED somehow.

    Code:
    s3user@s3m1:/var/run/mysqld$ apt-get remove --purge mysql-server
    E: Could not open lock file /var/lib/dpkg/lock - open (13: Permission denied)
    E: Unable to lock the administration directory (/var/lib/dpkg/), are you root?
    s3user@s3m1:/var/run/mysqld$ sudo apt-get remove --purge mysql-server
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    The following packages will be REMOVED:
      mysql-server*
    0 upgraded, 0 newly installed, 1 to remove and 21 not upgraded.
    2 not fully installed or removed.
    After this operation, 98.3 kB disk space will be freed.
    Do you want to continue [Y/n]? Y
    (Reading database ... 191231 files and directories currently installed.)
    Removing mysql-server ...
    Setting up mysql-server-5.1 (5.1.58-1ubuntu1) ...
    111207 14:44:43 [Note] Plugin 'FEDERATED' is disabled.
    111207 14:44:43  InnoDB: Initializing buffer pool, size = 8.0M
    111207 14:44:43  InnoDB: Completed initialization of buffer pool
    111207 14:44:43  InnoDB: Started; log sequence number 0 1595675
    111207 14:44:43  InnoDB: Starting shutdown...
    111207 14:44:48  InnoDB: Shutdown completed; log sequence number 0 1595675
    start: Job failed to start
    invoke-rc.d: initscript mysql, action "start" failed.
    dpkg: error processing mysql-server-5.1 (--configure):
     subprocess installed post-installation script returned error exit status 1
    Errors were encountered while processing:
     mysql-server-5.1
    E: Sub-process /usr/bin/dpkg returned an error code (1)
    This puts me back to square 1, where MySQL installs incorrectly.

    I would really like it if I could just have MySQL working for me. I want to get to the point where I can have multiple instances of MySQL running, and be able to debug MySQL. For this, I would be so grateful!

    Before I did all the steps above, I had a generic binary install of MySQL 5.5.18 installed and running fine. I took the following steps to remove it:

    Code:
    s3user@s3m1:~$ sudo rm /etc/ld.so.conf.d/mysql
    s3user@s3m1:~$ sudo rm /etc/mysql/my.cnf
    s3user@s3m1:~$ sudo rm -r /usr/local/mysql
    s3user@s3m1:~$ sudo rm /var/log/mysql/error.log
    I really hope removing this previous installation had nothing to do with the problems I'm having now. With some midifications for a few files, the previous installation was done using the guide provided by MySQL: http://dev.mysql.com/doc/refman/5.5/...tallation.html

  2. #2
    Join Date
    Oct 2011
    Beans
    1

    Re: 11.10 MySQL install errors, doesn't work, cant uninstall either!

    I tried this and it worked for me.
    After uninstalled and cleaned everything mysql
    sudo apt-get remove mysql-server-5.1
    sudo apt-get purge mysql-common
    sudo apt-get purge mysql-server-5.1
    sudo apt-get autoremove
    sudo apt-get clean

    1. Install mysql-common first
    sudo apt-get install mysql-common

    2. Install the rest of mysql
    sudo apt-get install mysql-server

    And the problem solved.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •