[Bug 2120936] Re: logrotate returns an error if mysql service is disabled
Ghadi Rahme
2120936 at bugs.launchpad.net
Tue Sep 9 08:12:10 UTC 2025
autopkgtests on Noble are not related to the patch:
For exim4 the issue is TLS related:
96s *** TLS startup failed (connect(): error:0A000438:SSL routines::tlsv1 alert internal error)
96s *** STARTTLS attempted but failed
97s *** Remote host closed connection unexpectedly.
For watcher it seems it timed out:
10433s autopkgtest [15:15:02]: test autodep8-python3: [-----------------------
10435s Testing with python3.12:
10435s <module 'watcher' from '/usr/lib/python3/dist-packages/watcher/__init__.py'>
10435s autopkgtest [15:15:04]: test autodep8-python3: -----------------------]
10439s autodep8-python3 PASS (superficial)
10439s autopkgtest [15:15:08]: test autodep8-python3: - - - - - - - - - - results - - - - - - - - - -
10442s autopkgtest [15:15:11]: @@@@@@@@@@@@@@@@@@@@ summary
10442s watcher-daemons FAIL timed out
10442s autodep8-python3 PASS (superficial)
Would it be possible to restart these tests?
--
You received this bug notification because you are a member of Ubuntu
Sponsors, which is subscribed to the bug report.
https://bugs.launchpad.net/bugs/2120936
Title:
logrotate returns an error if mysql service is disabled
Status in mysql-8.0 package in Ubuntu:
New
Status in mysql-8.4 package in Ubuntu:
Fix Released
Status in mysql-8.0 source package in Jammy:
Fix Committed
Status in mysql-8.0 source package in Noble:
Fix Committed
Status in mysql-8.4 source package in Plucky:
Fix Committed
Status in mysql-8.4 source package in Questing:
Fix Released
Bug description:
[Description]
After the MR part of this bug report:
https://bugs.launchpad.net/ubuntu/+source/mysql-8.0/+bug/1850980
logrotate returns an error when running the mysql log rotation script
if the mysql service is disabled.
It is expected of logrotate not to return an error if the service is disabled since a disabled service will not generate logs to rotate anyways.
I have written a fix that checks first the status of the mysql service before running the rest of the log rotate script.
[Test Plan]
Run the following commands, and verify the output of logrotate:
$ sudo apt install mysql-server
$ sudo systemctl stop mysql.service
$ sudo logrotate -f /etc/logrotate.conf
If no error is returned by logrotate it means the fix was successful,
else the following error is shown:
error: error running shared postrotate script for '/var/log/mysql.log
/var/log/mysql/*log '
[Where problems could occur]
Since the changes is related to logs, possible issues may be that the script falsely detects that the mysql service is disabled and not rotate the logs.
Any problems resulting from this patch are expected to only be limited to log rotation.
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/mysql-8.0/+bug/2120936/+subscriptions
More information about the Ubuntu-sponsors
mailing list