今天博客数据库再一次停了,这都是第二次了。不知道是不是服务器维护系统停过。

数据库常用命令:

systemctl start mariadb

systemctl enable mariadb.service

 

#service mysql status
● mariadb.service - MariaDB database server
Loaded: loaded (/lib/systemd/system/mariadb.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Tue 2018-06-12 19:58:49 UTC; 6h ago
Process: 20960 ExecStartPost=/bin/sh -c systemctl unset-environment _WSREP_START_POSITION (code=exited, status=0/SUCCESS
)
Process: 20958 ExecStartPost=/etc/mysql/debian-start (code=exited, status=0/SUCCESS)
Process: 756 ExecStart=/usr/sbin/mysqld $MYSQLD_OPTS $_WSREP_NEW_CLUSTER $_WSREP_START_POSITION (code=exited, st
atus=1/FAILURE)
Process: 665 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 (code=exited, status=0/SUCCESS)
Process: 659 ExecStartPre=/bin/sh -c systemctl unset-environment _WSREP_START_POSITION (code=exited, status=0/SUCCESS)
Process: 658 ExecStartPre=/usr/bin/install -m 755 -o mysql -g root -d /var/run/mysqld (code=exited, status=0/SUCCESS)
Main PID: 756 (code=exited, status=1/FAILURE)
Status: "MariaDB server is down"
Jun 12 19:58:48 instance-2 systemd[1]: Starting MariaDB database server...
Jun 12 19:58:49 instance-2 mysqld[756]: 2018-06-12 19:58:49 139872617685568 [Note] /usr/sbin/mysqld (mysqld 10.1.26-MariaD
B-0+deb9u1) starting as process 756 ...
Jun 12 19:58:49 instance-2 systemd[1]: mariadb.service: Main process exited, code=exited, status=1/FAILURE
Jun 12 19:58:49 instance-2 systemd[1]: Failed to start MariaDB database server.
Jun 12 19:58:49 instance-2 systemd[1]: mariadb.service: Unit entered failed state.
Jun 12 19:58:49 instance-2 systemd[1]: mariadb.service: Failed with result 'exit-code'.
root@instance-2:~# led state.
-bash: led: command not found
#
# Jun 12 19:58:49 instance-2 systemd[1]: mariadb.service: Failed with result 'exit-code'.
-bash: Jun: command not found

Leave a Reply

Your email address will not be published. Required fields are marked *