[debian-mysql] Bug#830976: logrotate failures if mysql server is not running
Michael Biebl
biebl at debian.org
Wed Jul 13 13:21:11 UTC 2016
Package: mariadb-server-10.0
Version: 10.0.26-1
Severity: normal
File: /etc/logrotate.d/mysql-server
Hi,
I have the mysql/mariadb server installed but not enabled and started by
default on my testing machine, as I only need the server occasionally.
I regularly get failure messages from cron when logrotate is run:
/etc/cron.daily/logrotate:
^Gmysqladmin: connect to server at 'localhost' failed
error: 'Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2 "No such file or directory")'
Check that mysqld is running and that the socket: '/var/run/mysqld/mysqld.sock' exists!
error: error running shared postrotate script for '/var/log/mysql/mysql.log /var/log/mysql/mysql-slow.log
/var/log/mysql/mariadb-slow.log /var/log/mysql/error.log '
run-parts: /etc/cron.daily/logrotate exited with return code 1
I think the logrotate config should handle it gracefully if the mysql
server is not running.
Regards,
Michael
-- System Information:
Debian Release: stretch/sid
APT prefers unstable
APT policy: (500, 'unstable'), (200, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386
Kernel: Linux 4.6.0-1-amd64 (SMP w/4 CPU cores)
Locale: LANG=de_DE.UTF-8, LC_CTYPE=de_DE.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
Versions of packages mariadb-server-10.0 depends on:
ii adduser 3.115
ii debconf [debconf-2.0] 1.5.59
ii libaio1 0.3.110-3
ii libc6 2.23-1
ii libdbi-perl 1.636-1
ii libpam0g 1.1.8-3.3
ii libstdc++6 6.1.1-9
ii lsb-base 9.20160629
ii mariadb-client-10.0 10.0.26-1
ii mariadb-common 10.0.26-1
ii mariadb-server-core-10.0 10.0.26-1
ii passwd 1:4.2-3.1
ii perl 5.22.2-2
ii psmisc 22.21-2.1+b1
ii zlib1g 1:1.2.8.dfsg-2+b1
Versions of packages mariadb-server-10.0 recommends:
ii libhtml-template-perl 2.95-2
Versions of packages mariadb-server-10.0 suggests:
ii bsd-mailx [mailx] 8.1.2-0.20160123cvs-3
pn mariadb-test <none>
ii tinyca 0.7.5-6
-- Configuration Files:
/etc/logcheck/ignore.d.paranoid/mariadb-server-10_0 [Errno 13] Keine Berechtigung: u'/etc/logcheck/ignore.d.paranoid/mariadb-server-10_0'
/etc/logcheck/ignore.d.server/mariadb-server-10_0 [Errno 13] Keine Berechtigung: u'/etc/logcheck/ignore.d.server/mariadb-server-10_0'
-- debconf information excluded
More information about the pkg-mysql-maint
mailing list