Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


Cannot install MariaDB
New on LowEndTalk? Please Register and read our Community Rules.

All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.

Cannot install MariaDB

So I have this issue with one of my servers which is doing my head in. Spent a couple of days trying to figure it out and I'm probably overlooking something basic. I have this 512Mb Ram VPS running Debian 8, a fresh minimal install but whatever I do MariaDb won't install.

It asks me to set the root password, confirms it, installs some dependencies and then here's what I get:

dpkg: error processing package mariadb-server-10.0 (--configure):
 subprocess installed post-installation script returned error exit status 1
Setting up libdbd-mysql-perl (4.028-2+deb8u2) ...
Setting up libhtml-template-perl (2.95-1) ...
dpkg: dependency problems prevent configuration of mariadb-server:
 mariadb-server depends on mariadb-server-10.0 (>= 10.0.28-0+deb8u1); however:
  Package mariadb-server-10.0 is not configured yet.

dpkg: error processing package mariadb-server (--configure):
 dependency problems - leaving unconfigured
Processing triggers for libc-bin (2.19-18+deb8u6) ...
Processing triggers for systemd (215-17+deb8u5) ...
Errors were encountered while processing:
 mariadb-server-10.0
 mariadb-server
E: Sub-process /usr/bin/dpkg returned an error code (1)

Any thought on what it might be or where to look? I tried about everything I could think of or found related this on Google. Any help would be much appreciated :)

Comments

  • tried doing an:
    apt-get install -f

  • mailcheapmailcheap Member, Host Rep
    edited November 2016

    Have you tried changing the sources file to use Debian's official repository instead of the provider's?

  • @doughnet said:
    tried doing an:
    apt-get install -f

    Yeah :( :

    Reading package lists... Done
    Building dependency tree
    Reading state information... Done
    0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
    2 not fully installed or removed.
    After this operation, 0 B of additional disk space will be used.
    Setting up mariadb-server-10.0 (10.0.28-0+deb8u1) ...
    debconf: unable to initialize frontend: Dialog
    debconf: (No usable dialog-like program is installed, so the dialog based frontend cannot be used. at /usr/share/perl5/Debconf/FrontEnd/Dialog.pm line 76.)
    debconf: falling back to frontend: Readline
    dpkg: error processing package mariadb-server-10.0 (--configure):
    subprocess installed post-installation script returned error exit status 1
    dpkg: dependency problems prevent configuration of mariadb-server:
    mariadb-server depends on mariadb-server-10.0 (>= 10.0.28-0+deb8u1); however:
    Package mariadb-server-10.0 is not configured yet. dpkg: error processing package mariadb-server (--configure):
    dependency problems - leaving unconfigured
    Errors were encountered while processing:
    mariadb-server-10.0
    mariadb-server
    E: Sub-process /usr/bin/dpkg returned an error code (1)
  • @mailcheap said:
    Have you tried changing the sources file to use Debian's official repository instead of the provider's?

    Yeah tried that as well. Heck, even reinstalled and tried with Ubuntu but it's giving me the same issue.

  • Install Percona instead and drink a Martini.

    Thanked by 1vimalware
  • @deadbeef said:
    Install Percona instead and drink a Martini.

    Hehe, problem solved, case closed :). Nah gonna stick with MariaDb and can't stand the fact it won't work on just this one server. I'll get me a strong drink anyway though :)

    Thanked by 1deadbeef
  • Have you tried apt-get clean and then reboot and try reinstalling it?

  • mailcheapmailcheap Member, Host Rep

    @Saragoldfarb said:

    @mailcheap said:
    Have you tried changing the sources file to use Debian's official repository instead of the provider's?

    Yeah tried that as well. Heck, even reinstalled and tried with Ubuntu but it's giving me the same issue.

    Hmm.. strange; does this happen only with this provider and their Deb images? Ruling out the possibility of a broken image (try a custom ISO perhaps), it could be some weird router caching by the provider.

  • @northhosts said:
    Have you tried apt-get clean and then reboot and try reinstalling it?

    Yeah, tried that. No luck :(

  • Did you remove mysql and client properly before installing Mariadb?.

  • Similar to this question:
    http://askubuntu.com/questions/286476/cant-install-mariadb-5-5-or-10-in-ubuntu-12-04-mysqld-failed-to-start

    Interestingly, one answer mentioned that it caused by insufficient RAM of 512MB.

  • @mailcheap said:

    @Saragoldfarb said:

    @mailcheap said:
    Have you tried changing the sources file to use Debian's official repository instead of the provider's?

    Yeah tried that as well. Heck, even reinstalled and tried with Ubuntu but it's giving me the same issue.

    Hmm.. strange; does this happen only with this provider and their Deb images? Ruling out the possibility of a broken image (try a custom ISO perhaps), it could be some weird router caching by the provider.

    Yes it's just this one provider I'm having this issue with. I used to have a VM on another node with them running MariaDb but not sure if it was the same OS. Would be weird if more than one of their images was broken right? Might send them a ticket about it but I'd hate to bother them with something I could fix myself :)

  • @scpal said:
    Similar to this question:
    http://askubuntu.com/questions/286476/cant-install-mariadb-5-5-or-10-in-ubuntu-12-04-mysqld-failed-to-start

    Interestingly, one answer mentioned that it caused by insufficient RAM of 512MB.

    Cheers. Came across that one in my quest to solve this but it doesn't seem to be memory related. Ram shows up just fine, hardly using anything.

  • mailcheapmailcheap Member, Host Rep

    @Saragoldfarb It could also be related to what @scpal mentioned; maybe insufficient resources on this node (ovz?).

  • @northhosts said:
    Did you remove mysql and client properly before installing Mariadb?.

    I ran:

    
    sudo apt-get remove --purge mysql-server mysql-client mysql-common
    sudo apt-get autoremove
    sudo apt-get autoclean

    Should do the trick right?

  • SaragoldfarbSaragoldfarb Member
    edited November 2016

    @mailcheap said:
    @Saragoldfarb It could also be related to what @scpal mentioned; maybe insufficient resources on this node (ovz?).

    Yeah it is ovz. Mh... Interesting thought.

  • Can you run

    find / -name mysql*

    Does it find anything?

  • SaragoldfarbSaragoldfarb Member
    edited November 2016

    @northhosts said:
    Can you run

    find / -name mysql*

    Does it find anything?

    Yup.. big list... :)

    Removed it again, what remains:


    find / -name mysql*
    /etc/mysql
    /var/log/mysql.err
    /var/log/mysql.log
    /var/log/mysql
    /var/lib/mysql
    /var/lib/mysql/mysql
    /usr/share/vim/vim74/syntax/mysql.vim
  • Thats your issue - your trying to install mariadb on top of mysql :) - you need to remove it.

  • @northhosts said:
    Thats your issue - your trying to install mariadb on top of mysql :) - you need to remove it.

    I'll give it another look with a fresh install as I could've sworn I tried this before and nothing showed up :) just to make sure. Nice BF offer by the way :)

  • No problem, let us know how you get on :)

  • SaragoldfarbSaragoldfarb Member
    edited November 2016

    @Saragoldfarb said:

    @northhosts said:
    Thats your issue - your trying to install mariadb on top of mysql :) - you need to remove it.

    I'll give it another look with a fresh install as I could've sworn I tried this before and nothing showed up :) just to make sure. Nice BF offer by the way :)

    On a clean install all that shows up:

    find / -name mysql*

    /usr/share/vim/vim74/syntax/mysql.vim

    After trying to install MariaDB and getting the error:


    find / -name mysql*
    /etc/logrotate.d/mysql-server
    /etc/init.d/mysql
    /etc/mysql
    /etc/mysql/conf.d/mysqld_safe_syslog.cnf
    /var/log/mysql.err
    /var/log/mysql.log
    /var/log/mysql
    /var/lib/mysql
    /var/lib/mysql/mysql
    /var/lib/dpkg/info/mysql-common.conffiles
    /var/lib/dpkg/info/mysql-common.md5sums
    /var/lib/dpkg/info/mysql-common.postrm
    /var/lib/dpkg/info/mysql-common.list
    /var/cache/apt/archives/mysql-common_5.5.53-0+deb8u1_all.deb
    /usr/share/man/man1/mysqloptimize.1.gz
    /usr/share/man/man1/mysqlbinlog.1.gz
    /usr/share/man/man1/mysqlreport.1.gz
    /usr/share/man/man1/mysqlimport.1.gz
    /usr/share/man/man1/mysql_setpermission.1.gz
    /usr/share/man/man1/mysqlshow.1.gz
    /usr/share/man/man1/mysql_convert_table_format.1.gz
    /usr/share/man/man1/mysqlaccess.1.gz
    /usr/share/man/man1/mysql_waitpid.1.gz
    /usr/share/man/man1/mysql_upgrade.1.gz
    /usr/share/man/man1/mysqld_safe.1.gz
    /usr/share/man/man1/mysqlanalyze.1.gz
    /usr/share/man/man1/mysql_tzinfo_to_sql.1.gz
    /usr/share/man/man1/mysqlslap.1.gz
    /usr/share/man/man1/mysql_zap.1.gz
    /usr/share/man/man1/mysql_fix_extensions.1.gz
    /usr/share/man/man1/mysqlcheck.1.gz
    /usr/share/man/man1/mysql_plugin.1.gz
    /usr/share/man/man1/mysqld_multi.1.gz
    /usr/share/man/man1/mysqlrepair.1.gz
    /usr/share/man/man1/mysqldump.1.gz
    /usr/share/man/man1/mysql_install_db.1.gz
    /usr/share/man/man1/mysqlbug.1.gz
    /usr/share/man/man1/mysql_secure_installation.1.gz
    /usr/share/man/man1/mysql_find_rows.1.gz
    /usr/share/man/man1/mysqldumpslow.1.gz
    /usr/share/man/man1/mysqladmin.1.gz
    /usr/share/man/man1/mysqlhotcopy.1.gz
    /usr/share/man/man1/mysql.1.gz
    /usr/share/man/man8/mysqld.8.gz
    /usr/share/vim/vim74/syntax/mysql.vim
    /usr/share/mysql
    /usr/share/mysql/mysql_system_tables_data.sql
    /usr/share/mysql/mysql_system_tables.sql
    /usr/share/mysql/mysql_performance_tables.sql
    /usr/share/mysql/mysql_test_data_timezone.sql
    /usr/share/doc/mariadb-server-10.0/mysqld.sym.gz
    /usr/share/doc/mysql-common
    /usr/bin/mysqlanalyze
    /usr/bin/mysqlreport
    /usr/bin/mysql_setpermission
    /usr/bin/mysqloptimize
    /usr/bin/mysqlslap
    /usr/bin/mysql_waitpid
    /usr/bin/mysql_plugin
    /usr/bin/mysqlshow
    /usr/bin/mysql_secure_installation
    /usr/bin/mysqldumpslow
    /usr/bin/mysqladmin
    /usr/bin/mysql_convert_table_format
    /usr/bin/mysql_install_db
    /usr/bin/mysqlaccess
    /usr/bin/mysql
    /usr/bin/mysqldump
    /usr/bin/mysql_fix_extensions
    /usr/bin/mysqlhotcopy
    /usr/bin/mysql_tzinfo_to_sql
    /usr/bin/mysqld_multi
    /usr/bin/mysqld_safe
    /usr/bin/mysqlbinlog
    /usr/bin/mysql_find_rows
    /usr/bin/mysql_upgrade
    /usr/bin/mysqlcheck
    /usr/bin/mysql_zap
    /usr/bin/mysqlimport
    /usr/bin/mysqlbug
    /usr/bin/mysqlrepair
    /usr/lib/mysql
    /usr/lib/x86_64-linux-gnu/perl5/5.20/auto/DBD/mysql
    /usr/lib/x86_64-linux-gnu/perl5/5.20/auto/DBD/mysql/mysql.so
    /usr/lib/x86_64-linux-gnu/perl5/5.20/DBD/mysql.pm
    /usr/lib/x86_64-linux-gnu/perl5/5.20/DBD/mysql
    /usr/sbin/mysqld
    /run/systemd/generator.late/mysql.service
  • @mailcheap said:
    @Saragoldfarb It could also be related to what @scpal mentioned; maybe insufficient resources on this node (ovz?)

    I'm really starting to wonder if this could be the case. Just installed it on a 128Mb ram VM just fine.

  • Percona has wayy more goodies in their repo.

    I still haven't gotten around to playing with all the instrumention utils

  • rincewindrincewind Member
    edited November 2016

    Do an ltrace -C -f -o /tmp/output.log on your dpkg command. If your server has oversold memory I would expect a malloc to fail.

    EDIT: After running the command, do a grep malloc /tmp/output.log to check for NULL/0 values. NULL means malloc failed.

  • @vimalware said:
    Percona has wayy more goodies in their repo.

    I still haven't gotten around to playing with all the instrumention utils

    Looks awesome. Will play with it this weekend.

    What are good ways to bench test a MySQL server?

  • My thoughts/ideas based on the assumption that you're using Debian Jessie (official) repos:

    1. Can you avoid installing mariadb-server which is just a meta-package and instead try to only install mariadb-server-10.0

    2. Make sure you've run apt-get update just to be sure. [ensure that you've got the security updates - see point 5 below]

    3. If again you run into the same issues, it could be a problem with the post-install script of the package (you'll have to debug the .deb by extracting it to a temp folder and checking to see if there's anything stupid going on - this seems unlikely considering that you're saying this works on other systems fine from the same sources). Other option is to try and install the other pre-requisites directly (these pre-reqs being things like mariadb-client-10.0 mariadb-server-core-10.0 mysql-common mariadb-client-core-10.0)

    4. Hopefully one of the above steps will give you a clue on why something is failing

    5. Also, recently (11th Nov) there was a security fix which bumped the version to 28 (presumably from 27) but there is a changelog breakage from the main debian website for mariadb - so something is still broken and this may be the cause of the issue as well (for e.g: from https://packages.debian.org/jessie/mariadb-client-core-10.0 if you try to access the Debian Changelog http://metadata.ftp-master.debian.org/changelogs/main/m/mariadb-10.0/mariadb-10.0_10.0.28-0+deb8u1_changelog I get a 404 - this as I write this comment). apt-cache policy should help ensure that you're getting the 28 version of all the packages - please double check.

    HTH.

Sign In or Register to comment.