I've installed MariaDB 10.3.8 on Ubuntu 18 Server, as follows:
sudo apt-get install software-properties-common
sudo apt-key adv --recv-keys --keyserver hkp://keyserver.ubuntu.com:80 0xF1656F24C74CD1D8
sudo add-apt-repository 'deb [arch=amd64,arm64,ppc64el] http://sfo1.mirrors.digitalocean.com/mariadb/repo/10.3/ubuntu bionic main'
sudo apt update
sudo apt install mariadb-server
sudo apt install mariadb-client
It does not start:
sudo service mariadb start
Job for mariadb.service failed because the control process exited with error code.
See "systemctl status mariadb.service" and "journalctl -xe" for details.
Log:
systemctl status mariadb.service
● mariadb.service - MariaDB 10.3.8 database server
Loaded: loaded (/lib/systemd/system/mariadb.service; enabled; vendor preset: enabled)
Drop-In: /etc/systemd/system/mariadb.service.d
└─migrated-from-my.cnf-settings.conf
Active: failed (Result: exit-code) since Thu 2018-07-12 20:18:48 PDT; 46s ago
Docs: man:mysqld(8)
https://mariadb.com/kb/en/library/systemd/
Process: 3392 ExecStartPost=/etc/mysql/debian-start (code=exited, status=203/EXEC)
Process: 3359 ExecStart=/usr/sbin/mysqld $MYSQLD_OPTS $_WSREP_NEW_CLUSTER $_WSREP_START_POSITION (code=exited, status=0/SUCCESS)
Process: 3349 ExecStartPre=/bin/sh -c [ ! -e /usr/bin/galera_recovery ] && VAR= || VAR=`/usr/bin/galera_recovery`; [ $? -eq 0 ]
Process: 3342 ExecStartPre=/bin/sh -c systemctl unset-environment _WSREP_START_POSITION (code=exited, status=0/SUCCESS)
Process: 3332 ExecStartPre=/usr/bin/install -m 755 -o mysql -g root -d /var/run/mysqld (code=exited, status=0/SUCCESS)
Main PID: 3359 (code=exited, status=0/SUCCESS)
Status: "MariaDB server is down"
Then, I see a file that is missing:
sudo ls -l /etc/mysql/debian-start
ls: cannot access '/etc/mysql/debian-start': No such file or directory
Other files missing:
/etc/mysql/my.cnf
/etc/mysql/conf.d
/etc/mysql/mariadb.cnf
/etc/init.d/mysql
The data directory location is controlled by the datadir variable. Look at your /etc/mysql/my. cnf file to see where your installation of MariaDB is configured to store data. The default is /var/lib/mysql but it is often changed, like for example if you are using a RAID array.
Note that you can add some parameters when you pull the file, like –mariadb-server-version=<version> that will override the default MariaDB Server version. Then don't forget to give the execution right to the script you just downloaded. You can now install the MariaDB server.
If you are looking to set up MariaDB Server, it is often easiest to use a repository. The MariaDB Foundation has a repository configuration tool at https://mariadb.org/download/ and MariaDB Corporation provides a convenient shell script to configure access to their MariaDB Package Repositories.
MariaDB version numbers follow MySQL's numbering scheme up to version 5.5. Thus, MariaDB 5.5 offers all of the MySQL 5.5 features. There exists a gap in MySQL versions between 5.1 and 5.5, while MariaDB issued 5.2 and 5.3 point releases.
I found a solution:
The following command:
apt-get install --reinstall -o Dpkg::Options::="--force-confmiss" mariadb-server-10.3
Created some files:
/etc/mysql/conf.d
/etc/init.d/mysql
/etc/mysql/debian-start
And:
apt-get install --reinstall -o Dpkg::Options::="--force-confmiss" mysql-common
Created:
/etc/mysql/my.cnf
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With