[debian-mysql] Bug#799433: Solution: comment out line 1 in /etc/mysql/debian.cnf

Moritz Strohm ncc1988 at posteo.de
Wed Mar 2 14:04:47 UTC 2016


Package: mysql-server-5.5
Version: 5.5.46-0+deb8u1
Followup-For: Bug #799433


Hello


I had the same problem: After installing mysql-server-5.5 via apt-get, the MySQL start script failed to load and it took it a while to figure out that it can't start MySQL. MySQL was already running and therefore a second MySQL service couldn't be started.

After killing the running MySQL service I did the same steps as Janusz: Commenting out the mentioned part in /var/lib/dpkg/info/mysql-server-5.5.postinst and calling update-rc.d and invoke-rc.d manually. update-rc.d worked but invoke-rc.d failed:

invoke-rc.d mysql start
[FAIL] Starting MySQL database server: mysqld . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . failed!
invoke-rc.d: initscript mysql, action "start" failed.


But a mysql service was running after invocation of invoke-rc.d. The syslog (/var/log/syslog) told me where the problem was:

Mar  2 14:46:43 Cubietruck /etc/init.d/mysql[13977]: 1 processes alive and '/usr/bin/mysqladmin --defaults-file=/etc/mysql/debian.cnf ping' resulted in
Mar  2 14:46:43 Cubietruck /etc/init.d/mysql[13977]: error: Found option without preceding group in config file: /etc/mysql/debian.cnf at line: 1
Mar  2 14:46:43 Cubietruck /etc/init.d/mysql[13977]: Fatal error in defaults handling. Program aborted


The first two lines of /etc/mysql/debian.cnf:

/bin/grep: /etc/mysql/debian.cnf: No such file or directory
# Automatically generated for Debian scripts. DO NOT TOUCH!


By commenting out the first line the problem was solved, MySQL runs fine since then:

invoke-rc.d mysql start
[ ok ] Starting MySQL database server: mysqld . ..
[info] Checking for tables which need an upgrade, are corrupt or were 
not closed cleanly..


In conclusion, I think something in the automatic generation of /etc/mysql/debian.cnf went wrong and caused all this trouble.

Regards
Moritz Strohm



-- System Information:
Debian Release: 8.2
  APT prefers stable
  APT policy: (500, 'stable')
Architecture: armhf (armv7l)

Kernel: Linux 4.4.0 (SMP w/2 CPU cores)
Locale: LANG=nb_NO.utf8, LC_CTYPE=nb_NO.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: sysvinit (via /sbin/init)

Versions of packages mysql-server-5.5 depends on:
ii  adduser                3.113+nmu3
ii  debconf [debconf-2.0]  1.5.56
ii  initscripts            2.88dsf-59
ii  libc6                  2.19-18+deb8u1
ii  libdbi-perl            1.631-3+b1
ii  libgcc1                1:4.9.2-10
ii  libstdc++6             4.9.2-10
ii  lsb-base               4.1+Debian13+nmu1
ii  mysql-client-5.5       5.5.46-0+deb8u1
ii  mysql-common           5.5.46-0+deb8u1
ii  mysql-server-core-5.5  5.5.46-0+deb8u1
ii  passwd                 1:4.2-3
ii  perl                   5.20.2-3+deb8u1
ii  psmisc                 22.21-2
ii  zlib1g                 1:1.2.8.dfsg-2+b1

Versions of packages mysql-server-5.5 recommends:
ii  libhtml-template-perl  2.95-1

Versions of packages mysql-server-5.5 suggests:
pn  mailx   <none>
pn  tinyca  <none>

-- debconf information excluded



More information about the pkg-mysql-maint mailing list