Loading

Sunday, April 17, 2005

MySQL slow queries log

start safe_mysqld like this to catch slow queries:

./bin/safe_mysqld --log-slow-queries &

OR

To use it, you need to add --log-slow-queries to your mysqld startup.

I added it to my /etc/rc.d/init.d/mysql file like so:

$bindir/safe_mysqld --user=$mysql_daemon_user --datadir=$datadir --pid-file=$pid_file --log=$log_file --log-slow-queries &

It does appear to put stuff into a different place, namely:

/var/lib/mysql/hostname-slow.log

SHARE TWEET

Thank you for reading this article MySQL slow queries log With URL http://x-tutorials.blogspot.com/2005/04/mysql-slow-queries-log.html. Also a time to read the other articles.

0 comments:

Write your comment for this article MySQL slow queries log above!