apt-get purge mariadb leaving traces which stop mysql install

6,114

You forgot to remove the libmariadbclient18 package. Remove that first.

Share:
6,114

Related videos on Youtube

AlexLordThorsen
Author by

AlexLordThorsen

Software Developer and part time circus performer. I get to say "This is my circus, these are my monkeys."

Updated on September 18, 2022

Comments

  • AlexLordThorsen
    AlexLordThorsen over 1 year

    I'm trying to bug test a database issue with a website I'm working on. I would like to see if switching between mariadb and MySQL fixes the issue (however unlikely that is). I thought this would be a simple processes on a dev machine (I don't have any data to worry about / back up).

    I used the command

    sudo apt-get purge mariadb*
    

    and then I entered

    sudo apt-get install mysql-server
    

    And was surprised to receive this lovely error.

       invoke-rc.d: initscript mysql, action "start" failed.
    dpkg: error processing mysql-server-5.5 (--configure):
     subprocess installed post-installation script returned error exit status 1
    dpkg: dependency problems prevent configuration of mysql-server:
     mysql-server depends on mysql-server-5.5; however:
      Package mysql-server-5.5 is not configured yet.
    dpkg: error processing mysql-server (--configure):
     dependency problems - leaving unconfigured
    Setting up libmariadbclient18 (5.5.32+maria-1~precise) ...
    No apport report written because the error message indicates its a followup error from a previous failure.
                              Processing triggers for libc-bin ...
    ldconfig deferred processing now taking place
    Errors were encountered while processing:
     mysql-server-5.5
     mysql-server
    E: Sub-process /usr/bin/dpkg returned an error code (1)
    

    I tried dkpg --configure -a and was greeted with this

    Setting up mysql-server-5.5 (5.5.31-0ubuntu0.12.04.2) ...
    start: Job failed to start
    invoke-rc.d: initscript mysql, action "start" failed.
    dpkg: error processing mysql-server-5.5 (--configure):
     subprocess installed post-installation script returned error exit status 1
    dpkg: dependency problems prevent configuration of mysql-server:
     mysql-server depends on mysql-server-5.5; however:
      Package mysql-server-5.5 is not configured yet.
    dpkg: error processing mysql-server (--configure):
     dependency problems - leaving unconfigured
    Errors were encountered while processing:
     mysql-server-5.5
     mysql-server
    

    I noticed that there wasa line which said

    setting up libmariadbclient18
    

    which makes no sense to me since I purged mariadb* earlier. Anyone out there have an idea of what's going on?

    Update I went right to the heart of the issue and did

    sudo apt-get install mysql-client-5.5
    

    and was greeted with

    Note, selecting 'mariadb-client-5.5' instead of 'mysql-client-5.1'
    

    Not sure what's going on.

    update2

    sudo apt-get purge libmariadbclient-dev
    

    has me installing the correct client, still getting an error on install.

  • AlexLordThorsen
    AlexLordThorsen almost 11 years
    I did apt-get purge libmariadbclient18. went to install and saw this message. The following NEW packages will be installed: libdbd-mysql-perl libmariadbclient18 libmysqlclient18 mysql-client-5.5 mysql-server mysql-server-5.5 So it's not because I haven't uninstalled it. for some reason apt-get is installing mariadb's client.
  • AlexLordThorsen
    AlexLordThorsen almost 11 years
    So I found the reason why my client was installing mariadb's client. sudo apt-get purge libmariadbclient-dev made it so mysql-server installs the correct client. It does not, however, fix my error.