Its better to use first mysqldump with --single-transaction
, like:
mysqldump --single-transaction -u root -p mydb > mydb.sql
If above not working try below one.
You have to replace the definer’s for that procedures/methods, and then you can generate the dump without error.
You can do this like:
UPDATE `mysql`.`proc` p SET definer="root@localhost" WHERE definer="root@192.200.1.16"
3rd party edit
For mysql 8.0 the table proc does no longer exist. Try
SELECT * FROM information_schema.routines;