How to fix this it?

Job for mysql.service failed because the control process exited with error code. See “systemctl status mysql.service” and “journalctl -xe” for details.

When i restart my sql then above error will occur …

You might running out of RAM.

Can you run command below to check mysql error log?

tail -30 /var/log/mysql/error.log

using this command following error shows

tail: cannot open ‘/var/log/mysql/error.log’ for reading: No such file or directory

sudo mysqld --tc-heuristic-recover=ROLLBACK

and then

sudo service mysqld start

try this

ok thanks

same error not any change…

sorry:

tail -30 /var/lib/mysql/mysql-error.log

same error…

You have to provide more information so that people can help you. Which O/S, version etc are you running?
You need to show everyone some of the contents of the log files, but they cannot guess where they are without knowing the background

Ok sorry for that
I am using ubantu 16.04
and maria db version
mysql Ver 15.1 Distrib 10.1.34-MariaDB, for debian-linux-gnu (x86_64) using readline 5.2

While i start the mysql then the below error will occur …

Job for mysql.service failed because the control process exited with error code. See “systemctl status mysql.service” and “journalctl -xe” for details.

On ubuntu 16.04, the mysql log file is usually under /var/log/mysql/, so try
ls -ltr /var/log/* | grep -i mysql
If you can show the log content for the latest file, I’m sure the guys here can help you

Also look at the messages in
See “systemctl status mysql.service” and “journalctl -xe” for details.