USE databasename;

FLUSH TABLES WITH READ LOCK;


/* alternatively lock a single table:
LOCK TABLES customers READ;
*/

/* running my backup */
UNLOCK TABLES;