简体   繁体   中英

MAC OSX MySQL Query Log not writing

I have my my.cnf with this setting

[mysqld]
general_log =1
general_log_file = /var/log/mysqld.log
query_cache_type=1
query_cache_size=64M

also had it before set to

[mysqld]
log = /var/log/mysqld.log
query_cache_type=1
query_cache_size=64M

I know I had this working at one point but when I went to go tail it today I noticed it wasn't working. I have the file in /var/log and this is the permissions

-rw-r--r-- 1 _mysql wheel 0 Jul 26 10:27 mysqld.log

It was

-rw-r--r-- 1 root wheel 0 Jul 26 10:27 mysqld.log

The problem might the your version of mysql - general_log_file only works on versions 5.1.29 and above. If you have a lesser version (5.1.28 or lower, any 5.0), you have to use "log" not "general_log_file."

If this isn't it, let us know here and we'll take another run at it.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM