October 17 2020

CPanel automatically backup MySQL Database

Tagged Under : , ,

1. Login to your CPanel Account. 2. Find the Database you want to backup. 3. Get the Database MySQL Username and Password 4. Copy below cronjob command and replace chevronsuser to Current Database user and also chevronspassword and chevronsdatabase you use
/usr/bin/mysqldump -u chevronsuser -p'chevronspassword' chevronsdatabase > /home/chevronscode/public_html/backup/db_`date +\%Y\%m\%d\%H\%M`.sql
5. After that go to Cpanel Dashboard. 6. In “ADVANCED” section click on “Cron Jobs”. 7. Go to “Add New Cron Job” section. 8. In “Comman Setting” select Cron Job occurrence nature. 9. And then put the above script in Command. 10. Click “Add New Cron Job” to add the command.

Make a Comment

You must be logged in to post a comment.