[debian-mysql] Bug#806813: Could not open required defaults file: /etc/mysql/debian.cnf

積丹尼 Dan Jacobson jidanni at jidanni.org
Tue Dec 1 19:03:15 UTC 2015


Package: mysql-server-5.6
Version: 5.6.27-2
Severity: wishlist

Double messages upon disable:

# systemctl disable mysql
Synchronizing state of mysql.service with SysV init with /lib/systemd/systemd-sysv-install...
Executing /lib/systemd/systemd-sysv-install disable mysql
insserv: warning: current start runlevel(s) (empty) of script `mysql' overrides LSB defaults (2 3 4 5).
insserv: warning: current stop runlevel(s) (0 1 2 3 4 5 6) of script `mysql' overrides LSB defaults (0 1 6).
insserv: warning: current start runlevel(s) (empty) of script `mysql' overrides LSB defaults (2 3 4 5).
insserv: warning: current stop runlevel(s) (0 1 2 3 4 5 6) of script `mysql' overrides LSB defaults (0 1 6).

OK. I'll report those to the systemd package.

# systemctl stop mysql
# systemctl stop mysql
# systemctl stop mysql

# systemctl status  mysql
● mysql.service - MySQL Community Server
   Loaded: loaded (/lib/systemd/system/mysql.service; disabled; vendor preset: enabled)
   Active: inactive (dead) since 三 2015-12-02 02:49:42 CST; 1min 44s ago
 Main PID: 555 (code=exited, status=0/SUCCESS)

12月 02 02:46:15 jidanni5 mysqld_safe[555]: 151202 02:46:15 mysqld_safe Logging to '/var/log/mysql/error.log'.
12月 02 02:46:16 jidanni5 mysqld_safe[555]: 151202 02:46:16 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
12月 02 02:46:22 jidanni5 systemd[1]: Started MySQL Community Server.
12月 02 02:49:40 jidanni5 systemd[1]: Stopping MySQL Community Server...
12月 02 02:49:42 jidanni5 mysqld_safe[555]: Could not open required defaults file: /etc/mysql/debian.cnf
12月 02 02:49:42 jidanni5 mysqld_safe[555]: Fatal error in defaults handling. Program aborted
12月 02 02:49:42 jidanni5 mysqld_safe[555]: 151202 02:49:42 mysqld_safe mysqld from pid file /var/run/mysqld/mysqld.pid ended
12月 02 02:49:42 jidanni5 systemd[1]: Stopped MySQL Community Server.
12月 02 02:49:44 jidanni5 systemd[1]: Stopped MySQL Community Server.
12月 02 02:49:48 jidanni5 systemd[1]: Stopped MySQL Community Server.

"Could not open required defaults file: /etc/mysql/debian.cnf"
Could that be because you are running as
$ grep mys /etc/passwd
mysql:x:111:116:MySQL Server,,,:/nonexistent:/bin/false
while the file is
# ls -l /etc/mysql/debian.cnf
-rw------- 1 root root 333 2013-01-25  /etc/mysql/debian.cnf
perhaps?



More information about the pkg-mysql-maint mailing list