Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I would like to understand how this happened. I was running a query that would take a long time, but should not lock up any table. However, my dbs were practically down - it seems like it was being locked up by "FLUSH TABLES WITH READ LOCK"

03:21:31 select type_id, count(*) from guid_target_infos group by type_id 02:38:11 select type_id, count(*) from guid_infos group by type_id 02:24:29 FLUSH TABLES WITH READ LOCK

But i did not start this command. can someone tell me why it was started automatically?

share|improve this question

1 Answer 1

up vote 1 down vote accepted

My guess is that was probably a backup script running from cron. "FLUSH TABLES WITH READ LOCK". This is especially used in backups to filesystems with snapshots. More info here.

share|improve this answer
Interesting! But typically this runs w no problems. Why would it cause a lock up in the exact same time as my big select statement? –  mingyeow May 14 '10 at 17:54
my question is: do you have some kind of script running from cron that mighy be flushing tables with read lock? –  Marco Ramos May 14 '10 at 19:17

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.