Powershell スクリプトを使用して MySQL のバックアップを取っています。すべて正常に動作しますが、同じ DB にクエリを実行するとハングアップします。バックアップ中にデータベースをロックする方法は?
&cmd /c $MySQL_Dump_Path -h $mysql_server -port=$mysql_port -u $mysql_user --password=$mysql_password --routines --single-transaction --quick --no-autocommit --no-tablespaces $dbname| Out-File -FilePath ".\Backup\$Dump" -エンコーディング UTF8