某日重启mysql遇到以下错误
差错误日志
The error which had been highlighted.
Then
so you may find the three files the owner which is not mysql, so change the owner
bash-3.00# /etc/rc3.d/S99mysql startStarting MySQL.... ERROR! Manager of
pid-file quit without updating file.
差错误日志
081211 11:02:41 InnoDB: Starting shutdown...081211 11:02:42 InnoDB:
Shutdown completed; log sequence number 0 46419081211 11:02:42 [Note]
/opt/mysql6/bin/mysqld: Shutdown complete
081211 11:02:42 mysqld_safe mysqld
from pid file /opt/mysql6/data/testenv.atu.pid ended081211 11:04:23 mysqld_safe
Starting mysqld daemon with databases from /opt/mysql6/data081211 11:04:23
InnoDB: Started; log sequence number 0 46419081211 11:04:24 [ERROR] mysqld: File './mysql-bin.000018' not found (Errcode:
13)081211 11:04:24 [ERROR] Failed to open log (file './mysql-bin.000018',
errno 13)081211 11:04:24 [ERROR] Could not open log file081211 11:04:24 [ERROR]
Can't init tc log081211 11:04:24 [ERROR] Aborting
081211 11:04:24
InnoDB: Starting shutdown...081211 11:04:25 InnoDB: Shutdown completed;
log sequence number 0 46419081211 11:04:25 [Note] /opt/mysql6/bin/mysqld:
Shutdown complete
081211 11:04:25 mysqld_safe mysqld from pid file
/opt/mysql6/data/testenv.atu.pid ended
The error which had been highlighted.
Then
bash-3.00# ../bin/perror 13OS error code 13: Permission denied
bash-3.00#ls -la
-rw-rw---- 1 root root 126 Dec 10 14:53 mysql-bin.000016
-rw-rw---- 1 root root 952 Dec 11 11:04 mysql-bin.000017
-rw-rw---- 1 root root 684783 Dec 11 11:04 mysql-bin.000018
so you may find the three files the owner which is not mysql, so change the owner
bash-3.00# chown mysql:mysql mysql-bin.000016
bash-3.00# chown mysql:mysql mysql-bin.000017
bash-3.00# chown mysql:mysql mysql-bin.000018
bash-3.00# /etc/rc3.d/S99mysql startStarting MySQL... SUCCESS!
评论