MySQL logrotate : not installed automatically

Hi,
I have FreePBX installed from a distro CD image somewhere in August/September IIRC.

I’ve ‘just’ discovered that logrotate does not automagically work out of the box…

My /var/log/mysql/mysql.log has grown to 29 GB (yes gigabytes).

The /etc/my.cnf also had 2 different log paths (general-log which was the above; and error-log /var/log/mysqld.log, invoked from [mysqld_safe] config section, but that did not log anything for a loooong long time.); Logrotate did not know anything about the file that has grown that big.

I had to adjust the paths in /etc/logrotate.d/mysql and run logrotate -f manually.
(I really hope it will not crash while gzipping the 29GB file :L ) (edit: it worked).

Does this constitute to be worthwhile to put it as a distro enhancement request or bug ?

Kind Regards
el es

Log rotate is probably installed but does not rotate the mySQL logs out of the box.

Yes. Seems all that was needed was uncommenting the pre-configured template in /etc/logrotate.d/mysql and adjusting paths in this and /etc/my.cnf, and then the manual rotate worked (and i gather, automatic rotate should then work either? No reload required?)
el_es

http://issues.freepbx.org/browse/FREEPBX-8155

Wow.
in that case, please note you have 2 log file paths defined by default in /etc/my.cnf - since one is ‘general’ log and the other is ‘error-log’, might actually be a good idea to keep them separate and separately rotated (the error-log one IIRC is /var/log/mysqld.log and there was NO logrotate definition of that - well originally that would be the one to rotate if only the /etc/logrotate.d/mysqld section was just uncommented).