When I try to dump mysql data, via a command from a Python script
subprocess.run('mysqldump --skip-triggers --single-transaction -u myuser -h localhost mydb | gzip > /home/user1/backup.sql.gz', shell=True, check=True, env=env)
, I will receive this error message:
mysqldump: Error: 'Access denied; you need (at least one of) the PROCESS privilege(s) for this operation' when trying to dump tablespaces
How can I resolve this?