0

I have upgraded my PHP from version 5.6 to 7.2 and now MySQL does not work. When I enter sudo service mysqsl start, the following text gets displayed:

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

output of journalctl -xe

output of systemctl status mysql.service:

mysql.service - LSB: Start and stop the mysql database server daemon
   Loaded: loaded (/etc/init.d/mysql)
   Active: failed (Result: exit-code) since \u0633\u0647\u200c\u0634\u0646\u0628\u0647 2018-07-17 04:22:01 +0430; 27s ago
     Docs: man:systemd-sysv-generator(8)
  Process: 26938 ExecStop=/etc/init.d/mysql stop (code=exited, status=0/SUCCESS)
  Process: 6860 ExecStart=/etc/init.d/mysql start (code=exited, status=1/FAILURE)
 Main PID: 9974 (code=exited, status=0/SUCCESS)

\u0698\u0648\u0626\u06cc\u0647 17 04:22:01 hutadmin-virtual-machine mysql[6860]: [97B blob data]
\u0698\u0648\u0626\u06cc\u0647 17 04:22:01 hutadmin-virtual-machine mysql[6860]: Fatal error in defaults handling. Program aborted
\u0698\u0648\u0626\u06cc\u0647 17 04:22:01 hutadmin-virtual-machine /etc/init.d/mysql[7565]: 0 processes alive and '/usr/bin/mysqladmin --defaults-file=/etc/mysql/debian.cnf ping' resulted in
\u0698\u0648\u0626\u06cc\u0647 17 04:22:01 hutadmin-virtual-machine /etc/init.d/mysql[7565]: [61B blob data]
\u0698\u0648\u0626\u06cc\u0647 17 04:22:01 hutadmin-virtual-machine /etc/init.d/mysql[7565]: error: 'Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)'
\u0698\u0648\u0626\u06cc\u0647 17 04:22:01 hutadmin-virtual-machine mysql[6860]: ...fail!
\u0698\u0648\u0626\u06cc\u0647 17 04:22:01 hutadmin-virtual-machine systemd[1]: mysql.service: Control process exited, code=exited status=1
\u0698\u0648\u0626\u06cc\u0647 17 04:22:01 hutadmin-virtual-machine systemd[1]: Failed to start LSB: Start and stop the mysql database server daemon.
\u0698\u0648\u0626\u06cc\u0647 17 04:22:01 hutadmin-virtual-machine systemd[1]: mysql.service: Unit entered failed state.
\u0698\u0648\u0626\u06cc\u0647 17 04:22:01 hutadmin-virtual-machine systemd[1]: mysql.service: Failed with result 'exit-code'.

How can I fix this problem? I need to start MySQL.

7
  • 1
    You need to post the output of "journalctl -xe" to get more help. Jul 16, 2018 at 22:25
  • @BernardWei I posted that Jul 16, 2018 at 23:06
  • I can't see the start of your attempt to start the mysql service in the journal log. You need to try to start the mysql service, then follow by issuing the journal command. Also make your terminal wider, the important messages seem to have been clipped off on the right side. Jul 17, 2018 at 1:03
  • @BernardWei I put all output of journal in a file, u can download it. Its link is in my question. thank you Jul 17, 2018 at 1:35
  • While upgrading PHP version did you get any errors
    – Muthusamy
    Jul 17, 2018 at 13:59

0

You must log in to answer this question.

Browse other questions tagged .