Description of problem: Since version 5.1.20, mysql has the --syslog option, to send error messages to syslog. The only way to enable this a.t.m. is to remove the --log-error option from /etc/init.d/mysqld and replace it with --syslog. It would be great if I could specify a flag in /etc/sysconfig/mysqld to enable this.
Hm, why would you not want to set it in /etc/my.cnf? There's no /etc/sysconfig file associated with mysql and I don't feel a need to introduce one ...
Hi Tom, The init script explicitly sets the --log-error option, even if it's not defined in /etc/my.cnf, but --syslog and --log-error are mutually exclusive. I have this in /etc/my.cnf: [mysqld_safe] pid_file = /var/run/mysqld/mysqld.pid syslog But this has no effect. If log-error is not defined, the init script sets it to /var/log/mysqld.log, but it should only do this if either syslog is not defined or skip-syslog is defined. Of course things would have been much easier if mysql just supported --log-error=syslog...
Well, what I think we can do is just remove the --log-error parameter from the mysqld_safe call. In the default case, mysqld will pick up the setting from /etc/my.cnf anyway, and somebody who wants to change to syslog logging can just adjust my.cnf like you did. The only reason the init script cares about the error log file is that it wants to make sure the file has the right permissions, and if the file is created but then mysql doesn't use it, no harm done.
That sounds like a solid solution to me.
mysql-5.1.40-1.fc12 has been submitted as an update for Fedora 12. http://admin.fedoraproject.org/updates/mysql-5.1.40-1.fc12
mysql-5.1.40-1.fc11 has been submitted as an update for Fedora 11. http://admin.fedoraproject.org/updates/mysql-5.1.40-1.fc11
mysql-5.1.40-1.fc12 has been pushed to the Fedora 12 testing repository. If problems still persist, please make note of it in this bug report. If you want to test the update, you can install it with su -c 'yum --enablerepo=updates-testing update mysql'. You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F12/FEDORA-2009-11399
mysql-5.1.40-1.fc11 has been pushed to the Fedora 11 testing repository. If problems still persist, please make note of it in this bug report. If you want to test the update, you can install it with su -c 'yum --enablerepo=updates-testing update mysql'. You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F11/FEDORA-2009-11422
mysql-5.1.40-1.fc11 has been pushed to the Fedora 11 stable repository. If problems still persist, please make note of it in this bug report.
mysql-5.1.40-1.fc12 has been pushed to the Fedora 12 stable repository. If problems still persist, please make note of it in this bug report.