Mysqldump && locks

When using mysqldump to dump data, if using subqueries, you have to use “ — lock-all-tables”.

Credits to http://bookofzeus.com/articles/mysql/using-mysqldump-with-subqueries/