Control Web Panel
WebPanel => CentOS 7 Problems => Topic started by: alireza_salehi on January 14, 2020, 07:29:25 AM
-
hi
i want to create cron job like this from user panel:
mysqldump -u uuuu -pxxx --default-character-set=utf8 myuser_db | gzip > /home/myuser/backups/db-`date +\%Y\%m\%d-\%H\%M`.sql.gz
but date parameters never works and i see db-{Q3}.sql.gz in output folder,
how can i create a cron job inside user panel with date parameters and formatting?
-
Try to run the command in the console and check what happened. I suppose, you have to use double quotes in the path. "/home/myuser/backups/db-`date +\%Y\%m\%d-\%H\%M`.sql.gz"