Header Ads

ad728
  • Breaking News

    Step to set daily backup database by using Crontab in Centos

    1. Install Cron:
    sudo yum install vixie-cron crontabs
    2.Set Up Crontab:
    • Use command "sudo crontab -e" to open file crontab in order write backup script.
    • To edit file: Esc + Shift + I 
    • Past or write script backup

      Syntax:
      minute hour day month dayofweek** mysqldump -uuser dbname > /path/dbbackup_name.sql
      Example: Weekly backup.
      0 24 2,9,16,23,30 * * mysqldump -uuser -ppassword testdb > /mypath/backup.sql; 


      save file: Esc+w 
    •  checking crontab service
    •  
      
      
    
    
     

    Post Top Ad

    ad728

    Post Bottom Ad

    ad728