MySQL is gone. cannot restart

i tried to restart mysql server, got this error message: Job for mysql.service failed because the control process exited with error code. See “systemctl status mysql.service” and “journalctl -xe” for details.

after running the systemctl status mysql.service, i got this; ● mysql.service - LSB: Start and stop the mysql database server daemon Loaded: loaded (/etc/init.d/mysql; bad; vendor preset: enabled) Active: failed (Result: exit-code) since Mon 2017-11-27 06:28:38 UTC; 1min 39s ago Docs: man:systemd-sysv-generator(8) Process: 12186 ExecStart=/etc/init.d/mysql start (code=exited, status=1/FAILURE)

Nov 27 06:28:38 localhost /etc/init.d/mysql[12764]: 0 processes alive and '/usr/bin/mysqladmin --defaults-file=/etc/mysql/debian.cnf ping' resulted in
Nov 27 06:28:38 localhost /etc/init.d/mysql[12764]: [52B blob data]
Nov 27 06:28:38 localhost /etc/init.d/mysql[12764]: error: 'Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)'
Nov 27 06:28:38 localhost /etc/init.d/mysql[12764]: Check that mysqld is running and that the socket: '/var/run/mysqld/mysqld.sock' exists!
Nov 27 06:28:38 localhost /etc/init.d/mysql[12764]:
Nov 27 06:28:38 localhost mysql[12186]:    ...fail!
Nov 27 06:28:38 localhost systemd[1]: mysql.service: Control process exited, code=exited status=1
Nov 27 06:28:38 localhost systemd[1]: Failed to start LSB: Start and stop the mysql database server daemon.
Nov 27 06:28:38 localhost systemd[1]: mysql.service: Unit entered failed state.
Nov 27 06:28:38 localhost systemd[1]: mysql.service: Failed with result 'exit-code'.

i also have this message: I do: systemctl status mariadb.service I get: ● mariadb.service - MariaDB database server Loaded: loaded (/lib/systemd/system/mariadb.service; enabled; vendor preset: enable Drop-In: /etc/systemd/system/mariadb.service.d └─migrated-from-my.cnf-settings.conf Active: failed (Result: exit-code) since Wed 2017-09-13 11:26:44 UTC; 16s ago Process: 4210 ExecStart=/usr/sbin/mysqld $MYSQLD_OPTS $WSREPNEW_CLUSTER $WSREPST Process: 4055 ExecStartPre=/bin/sh -c [ ! -e /usr/bin/galera_recovery ] && VAR= || Process: 4052 ExecStartPre=/bin/sh -c systemctl unset-environment WSREPSTART_POSIT Process: 4050 ExecStartPre=/usr/bin/install -m 755 -o mysql -g root -d /var/run/mysq Main PID: 4210 (code=exited, status=1/FAILURE) Status: “MariaDB server is down” CGroup: /system.slice/mariadb.service └─3803 /usr/sbin/mysqld

when i check ee info, it says mysql is not installed. and mysql error logs are empty help!

First of all, check your disk space and inode usage.

Hi i have bout 5gb free disk space.

How do i check my inode usage?

Thanks

df -i

Filesystem Inodes IUsed IFree IUse% Mounted on /dev/root 1228608 254721 973887 21% / devtmpfs 126148 1378 124770 2% /dev tmpfs 126632 1 126631 1% /dev/shm tmpfs 126632 1206 125426 1% /run tmpfs 126632 2 126630 1% /run/lock tmpfs 126632 16 126616 1% /sys/fs/cgroup tmpfs 126632 4 126628 1% /run/user/1000

is this okay?

It is fine.

Try as root:

mysqld_safe

Let me know what this command outputs.

The program ‘mysqld_safe’ can be found in the following packages:

  • mysql-server-5.7
  • mariadb-server-10.0
  • percona-server-server-5.6
  • percona-xtradb-cluster-server-5.6 Try: apt install

ee stack install --mysql

got this. Adding repository for MySQL, please wait… Updating apt-cache, please wait… Installing packages, please wait… Oops Something went wrong!! Check logs for reason tail /var/log/ee/ee.log & Try Again!!!

running tail log Building dependency tree… Reading state information… percona-toolkit is already the newest version (2.2.16-1). You might want to run ‘apt-get -f install’ to correct these: The following packages have unmet dependencies: mariadb-server : Depends: mariadb-server-10.1 (= 10.1.29+maria-1~xenial) but it is not going to be installed mysql-server : Depends: mysql-server-5.7 but it is not going to be installed E: Unmet dependencies. Try ‘apt-get -f install’ with no packages (or specify a solution). 2017-11-27 15:26:25,521 (INFO) ee : Oops Something went wrong!! 2017-11-27 15:26:25,522 (ERROR) ee : Check logs for reason tail /var/log/ee/ee.log & Try Again!!!

runnning apt-get -f install i got this Preconfiguring packages … (Reading database … 37903 files and directories currently installed.) Preparing to unpack …/mysql-server-5.7_5.7.20-0ubuntu0.16.04.1_amd64.deb … Aborting downgrade from (at least) 10.1 to 5.7. If are sure you want to downgrade to 5.7, remove the file /var/lib/mysql/debian-*.flag and try installing again. dpkg: error processing archive /var/cache/apt/archives/mysql-server-5.7_5.7.20-0ubuntu0.16.04.1_amd64.deb (–unpack): subprocess new pre-installation script returned error exit status 1 Errors were encountered while processing: /var/cache/apt/archives/mysql-server-5.7_5.7.20-0ubuntu0.16.04.1_amd64.deb E: Sub-process /usr/bin/dpkg returned an error code (1)

Unfortunately I don’t know how to help you.

Perhaps you’ll have to hire an expert to solve this issue.

its okay @portofacil, i know you’re helpful. thank you so much perhaps the dev/owner is here? maybe he can help?

cuz i have not done anything to server for like a week. nobody touches it. pretty secure i would say.

so i would like to find out what is the cause of this.

I am one! :slight_smile: https://baab.de Or is this problem already solved?