dropbear to openSSH kills mariadb

hey there,

I have a basic instance running with only mariadb.
Changed dropbear to openSSH using dietpi-software, reboots and mariadb fails to start.

Turns out mysql.service now exists and is being started prior to mariadb.service.

I have resolved issue by disabling mysql.service, reboot and mariadb.service starts fine.

I tried this on a fresh dietpi image in virtualbox and it does exact same thing.

I know mariadb is forked from mysql, but do i now have more unneeded crud installed?

Hi,

many thanks for your report. I tried to replicate your issue but without success.

  1. basically I used a fresh installation
  2. installed MariaDB from dietpi-software
  3. rebooted
  4. checked the available services
  5. mariadb.service > active (running)
  6. mysql.service could not be found
  7. switched from Dropbear to OpenSSH Server using dietpi-software
  8. rebooted
  9. checked the available services
  10. mariadb.service > active (running)
  11. mysql.service could not be found
  12. everything is working as expected

During installation of MariaDB, services for MySQL should have been removed.

[  OK  ] DietPi-Software | APT install for: mariadb-server
[ INFO ] DietPi-Software | Switching from /etc/init.d/mysql to mariadb.service
Synchronizing state of mysql.service with SysV service script with /lib/systemd/systemd-sysv-install.
Executing: /lib/systemd/systemd-sysv-install disable mysql
Removed /etc/systemd/system/mysqld.service.
Removed /etc/systemd/system/mysql.service.

Pls can you let me know steps you did, to be able to reproduce the issue.

I have got it to fail again, please see my steps below.

Used the following virtual box image

==================================================
Filename : DietPi_VirtualBox-x86_64-Buster.ova
MD5 : 4ba0a77f5143139f1c4d981073858bde
SHA1 : d045468341792e237bad711c01425aa0d949d296
CRC32 : e5234733
SHA-256 : 9974c9c2f708e8e28b55c0702225a5d51592cd8d63eb1cd829030f52ff5f8a0b
SHA-512 : 1a0dffcc7369c2e30e860c88ca9200e217428b265270569f5ef7bb7b17f91cd169e38753d95ab9214cacbc1f7de449e069bb5833595b0f16dced3f3d239e3af8
SHA-384 : 624aa36d6007c559aed4cb01c5cfc203f8fceed543c16678c685e2a83bca371e741dff0e1db7368d31412bd43f5ed925
Modified Time : 31.07.2020 00:29:52
Created Time : 31.07.2020 00:29:13
Entry Modified Time: 31.07.2020 00:29:52
File Size : 201.613.312
Extension : ova
File Attributes : A

Import and run initial setup. Dietpi banner says it is version 6.32.2

I then ran sudo apt-get install mariadb-server (not from dietpi-software)
MariaDb installs, reboots everything is fine.

Then from Dietpi-software I change DropBear to OpenSSH, reboots and MariaDB fails to start.

I am not to worried as I have fixed issue, just thought I would mention it in case it affects other software :slight_smile:
dietpi.PNG

Is there are a particular reason why not using MariaDB from dietpi-sofware catalogue? Because exactly this could have been avoided as DietPi is doing some aftercare once MariaDB was installed :wink:

DietPi source code

systemctl disable --now mysql
rm /etc/init.d/mysql
update-rc.d -f mysql remove

Basically similar to what you have done now. :slight_smile:

Was just habit typing it into cli, will use Dietpi-Software next time :slight_smile: