sometimes, when i run the setup:upgrade command, magento2 stops on Magento2 Indexer (Runnign data recurring) for hours. Reading processlist under mysql server it looks like there is a problem on some queries like this one
DROP TRIGGER IF EXISTS `trg_cataloginventory_stock_item_after_insert
and the status is Waiting for table metadata lock.
if i kill the process and restartm, flushing cache, manual reindexing, it does the same.
What could i do?