Anonymous | Login | 2024-12-22 05:15 MST |
Main | My View | View Issues | Change Log | Roadmap | Repositories |
View Issue Details [ Jump to Notes ] | [ Issue History ] [ Print ] | ||||||||
ID | Project | Category | View Status | Date Submitted | Last Update | ||||
0000225 | ClearOS | app-mysql - MySQL Database | public | 2011-02-06 07:52 | 2019-03-12 04:21 | ||||
Reporter | NickH | ||||||||
Assigned To | |||||||||
Priority | normal | Severity | tweak | Reproducibility | have not tried | ||||
Status | closed | Resolution | suspended | ||||||
Platform | OS | OS Version | |||||||
Product Version | 5.2-SP1 | ||||||||
Target Version | Fixed in Version | ||||||||
Summary | 0000225: MySQL log does not rotate | ||||||||
Description | I recently noticed in 07/2009 mysqld.log ceased to rotate. This was probably in the transition from CC4.3 to CC5.0. There is no entry in logrotate.conf or /etc/logrotate.d to force log rotation. It is the same on both my production server and my play VM. | ||||||||
Tags | No tags attached. | ||||||||
Attached Files | |||||||||
Notes | |
(0000836) NickH (developer) 2013-05-01 05:07 |
system-mysql.log used to rotate in 5.2 but with a logrotate function a bit different from normal logrotate functions: /var/log/system-mysql/mysqld.log { missingok create 0640 system-mysql system-mysql prerotate [ -e /var/lock/subsys/system-mysqld ] && /bin/kill -HUP `cat /var/run/system-mysqld/system-mysqld.pid 2> /dev/null ` || /bin/true endscript postrotate [ -e /var/lock/subsys/system-mysqld ] && /bin/kill -HUP `cat /var/run/system-mysqld/system-mysqld.pid 2> /dev/null ` || /bin/true endscript } |
(0000838) NickH (developer) 2013-05-01 05:08 |
Sorry. Comment added to wrong bug |
(0001143) user2 2014-02-10 08:03 |
This was semi-resolved in a recent upstream update. See "Details" section in upstream errata report: https://rhn.redhat.com/errata/RHBA-2013-1647.html [^] The script to rotate the logs is included, but disabled. We'll add a little hook in the ClearOS MySQL app to enable/disable the script from the GUI. |
(0001187) user2 2014-05-28 20:04 |
The upstream logrotate configlet is below. As you can see, the script requires the database root password to be stored in /root/.my.cnf. That's messy. Instead of requiring the password, a full MySQL restart could be done instead? That's not ideal either. // Begin configlet # This logname can be set in /etc/my.cnf # by setting the variable "err-log" # in the [safe_mysqld] section as follows: # # [safe_mysqld] # err-log=/var/log/mysqld.log # # If the root user has a password you have to create a # /root/.my.cnf configuration file with the following # content: # # [mysqladmin] # password = <secret> # user= root # # where "<secret>" is the password. # # ATTENTION: This /root/.my.cnf should be readable ONLY # for root ! # Then, un-comment the following lines to enable rotation of mysql's log file: #/var/log/mysqld.log { # create 640 mysql mysql # notifempty # daily # rotate 3 # missingok # compress # postrotate # # just if mysqld is really running # if test -x /usr/bin/mysqladmin && \ # /usr/bin/mysqladmin ping &>/dev/null # then # /usr/bin/mysqladmin flush-logs # fi # endscript #} |
(0001357) user2 2015-01-29 12:47 |
Due to the added complexity, we're bumping this request to a later release. |
(0010911) NickH (developer) 2019-03-12 04:21 |
Migrated to: https://gitlab.com/clearos/clearfoundation/app-mariadb/issues/1 [^] |
Issue History | |||
Date Modified | Username | Field | Change |
2011-02-06 07:52 | NickH | New Issue | |
2011-02-07 20:34 | user2 | Status | new => acknowledged |
2013-02-02 09:42 | user2 | Target Version | => 6.4.0 Beta 2 |
2013-02-21 20:00 | user2 | Target Version | 6.4.0 Beta 2 => 6.4.0 |
2013-03-14 11:56 | user2 | Target Version | 6.4.0 => 6.4.0 Updates |
2013-04-30 14:29 | user2 | Issue cloned: 0001129 | |
2013-05-01 05:07 | NickH | Note Added: 0000836 | |
2013-05-01 05:08 | NickH | Note Added: 0000838 | |
2013-07-29 13:58 | user2 | Target Version | 6.4.0 Updates => 6 Future |
2014-02-10 08:03 | user2 | Note Added: 0001143 | |
2014-02-10 08:04 | user2 | Target Version | 6 Future => 6.5.0 Updates |
2014-02-10 08:05 | user2 | Target Version | 6.5.0 Updates => 6.6.0 Beta 1 |
2014-05-08 08:09 | user2 | Target Version | 6.6.0 Beta 1 => 6.6.0 Beta 2 |
2014-05-28 20:04 | user2 | Note Added: 0001187 | |
2014-05-30 13:46 | user2 | Severity | trivial => tweak |
2014-06-23 10:34 | user2 | Target Version | 6.6.0 Beta 2 => 6.6.0 Beta 3 |
2014-08-27 14:23 | user2 | Target Version | 6.6.0 Beta 3 => 7.0.0 Alpha 2 |
2014-10-21 15:28 | user2 | Target Version | 7.0.0 Alpha 2 => 7.1.0 Beta 2 |
2015-01-29 12:47 | user2 | Note Added: 0001357 | |
2015-01-29 12:47 | user2 | Target Version | 7.1.0 Beta 2 => |
2019-03-12 04:21 | NickH | Note Added: 0010911 | |
2019-03-12 04:21 | NickH | Status | acknowledged => closed |
2019-03-12 04:21 | NickH | Resolution | open => suspended |