Restarting mysql failed with error 11

Hello guys
I have seen this error multiple blogs before but the way around still confusing. I patched my server from Mariadb 10.30.35 to 10.3.36 today and everything was fine. When I tried systemctl start Mariadb I found out mariadb was unable to start.

Mysqld:can’t lock aria control file ‘/mydata /aria_log_control’ for exclusive use, error:11 will retry in 30 seconds
Mysqld got error ‘could not get an exclusive lock: file is probably in use by another process’ when trying to use aria control file ‘/mydata/aria_log_control’

Any way around ? Is this a bug ? Please

1 Like

Hi @Dba1

Thank you for being part of the Percona Community. Could you tell me what filesystem you are using? Usually, error 11 means that the resource is not available temporarily. This kind of error messages
are generated by the filesystem because the file is locked by another process.

Also check that you don’t have any instance of mariadb running.




Also check if SELinux is in ENFORCING mode, if you are on CentOS/RHEL/Rocky. You might need to change to PERMISSIVE mode, since your $datadir is in a non-standard location.


Thanks @Pep_Pla I was able to resolve yesterday. I am just coming back here. Basically when I restarted mariadb I found out that another daemon was running underground which was using resources…
Fixed by

Systemctl stop mysqld.service. I restarted mariadb and it worked. Once again thank you


Big thanks @matthewb you are always there. I was able to resolve just replying the trend again I know I’m late. Can you please explain what you mean my data is in standard place.

1 Like

/mydata/ is not standard/default. /var/lib/mysql is the default. SELinux usually doesn’t like it when you move things away from the default due to the security contexts.

1 Like