Running backup script scheduled creates empty backup file

12/13/2021

I wrote the kubernetes mysql backup script , the script was working fine in manually , but enable the scheduling empty backup file only created?

kubectl exec mysql-0 -n autotat-qa -- mysqldump -u root  --password=root123! --all-databases --single-transaction --quick --lock-tables=false | gzip > /home/ec2-user/backups/mysql/backups/$(date +%Y%m%d%H%M%S).sql.gz
-- Yogesh
cron
kubernetes
mysql

0 Answers