Hello Faustin,

I am unfamiliar with how libvirt works, so I cannot say.

I have debian testing running on the hardware and inside the container.  Everything is from official repo.  I can get mariadb to start by messing around with the systemd startup script.

This may entirely be a an apparmor/systemd issue and nothing to to with mariadb.  But I'm not clear if mariadb systemd configuration is doing something unexpected or not.

It works, if I create /var/run/mysqld by hand, and then use this /lib/systemd/system/mariadb.service:

[Unit]
Description=MariaDB 10.3.12 database server
Documentation=man:mysqld(8)
Documentation=https://mariadb.com/kb/en/library/systemd/
After=network.target

[Install]
WantedBy=multi-user.target
Alias=mysql.service
Alias=mysqld.service

[Service]
Type=notify
PrivateNetwork=false
User=mysql
Group=mysql
CapabilityBoundingSet=CAP_IPC_LOCK
PermissionsStartOnly=true
ExecStartPre=/bin/sh -c "systemctl unset-environment _WSREP_START_POSITION"
ExecStartPre=/bin/sh -c "[ ! -e /usr/bin/galera_recovery ] && VAR= || \
 VAR=`/usr/bin/galera_recovery`; [ $? -eq 0 ] \
 && systemctl set-environment _WSREP_START_POSITION=$VAR || exit 1"
ExecStart=/usr/sbin/mysqld $MYSQLD_OPTS $_WSREP_NEW_CLUSTER $_WSREP_START_POSITION
ExecStartPost=/etc/mysql/debian-start
ExecStartPost=/bin/sh -c "systemctl unset-environment _WSREP_START_POSITION"
KillSignal=SIGTERM
SendSIGKILL=no
Restart=on-abort
RestartSec=5s
UMask=007
PrivateTmp=false
LimitNOFILE=16364


On 2019-02-11 11:35 a.m., Faustin Lammler wrote:
Hi Matthew,
Thanks for your report!

I have no platform setup to test this so I have to install one but I am
not a LXC expert. Do you think this could be tested into a libvirt VM?

If I understand correctly, you have a Debian testing host and you are
running an LXC container with 10.3 mariadb version (everything from
official Debian repositories?).

This (https://github.com/lxc/lxc/pull/2758) seems to indicate that
problem may rather come from apparmor/systemd but I will try to
reproduce your issue.

Regards,
Faustin

Reply via email to