MySQL General log not working on Mac OS X I want to log all queries to the database running on my MacBook Pro (Mac OS X 10.8.1). I created a file /etc/my.cnf with the following content:

[mysqld]
general_log=1
general_log_file=/Users/wdb/mysql.log


I restarted MySQL and tried some queries on the mysql command line, but nothing gets logged. The file is not getting created. I also created the file myself afterwards to test with touch, but the file remains empty.

When I check, MySQL did read my settings:

mysql&gt; show variables like '%general_log%';
+------------------+----------------------+
| Variable_name    | Value                |
+------------------+----------------------+
| general_log      | ON                   |
| general_log_file | /Users/wdb/mysql.log |
+------------------+----------------------+
2 rows in set (0.01 sec)


Is there anything else I need to do? I suppose any query I type on the command line should get logged, right?

I am using MySQL 5.5.24
The problem is indeed as @Phil hinted at. To fix it, set the permissions for the _mysql user:

&gt; cd ~
&gt; touch mysql.log
&gt; sudo chown _mysql:wheel mysql.log


Restart MySQL after that and the log file will be used.