Facebook Twitter Instagram
    TecAdmin
    • Home
    • Ubuntu 20.04
      • Upgrade Ubuntu
      • Install Java
      • Install Node.js
      • Install Docker
      • Install LAMP Stack
    • Tutorials
      • AWS
      • Shell Scripting
      • Docker
      • Git
      • MongoDB
    • FeedBack
    • Submit Article
    • About Us
    Facebook Twitter Instagram
    TecAdmin
    Home»Uncategorized»MySQL Database Backup RPM

    MySQL Database Backup RPM

    RahulBy RahulApril 18, 20132 Mins Read

    I had created this rpm few months back. Now it is available for all users. This rpm have a simple shell script for mysql database backup.

    Features:
    • Takes database backup locally.
    • Upload backups to ftp server.
    • Send email alerts on backup completed.
    Installation:

    Download this rpm directly using command line or using given below download link and install it.

    [wpdm_file id=4]

    # wget https://tecadmin.net/wp-content/downloads/rpms/mydumpadmin-1-0.noarch.rpm
    
    # rpm -ivh mydumpadmin-1-0.noarch.rpm
    
    Preparing...                ########################################### [100%]
       1:mydumpadmin            ########################################### [100%]
    
    Thank you for installing this RPM.
    Configure backup settings in /etc/mydumpadmin/settings.conf file
    Setup /etc/mydumpadmin/mysql-dump.sh script in your cron to take backup automatically
    0 2 * * *  /bin/sh /etc/mydumpadmin/mysql-dump.sh
    
    Configuration:

    To configure edit settings file ( /etc/mydumpadmin/settings.conf ) in your favorite editor and make changes as per your requirements.

    MYSQLUSER : Enter your mysql admin account
    MYSQLPASSWORD : MySQL admin account password
    MYSQLHOSTNAME : Enter systems host name
    
    FTP_ENABLE  : 1=enable,  0=disable.
    FTP_SERVER : Enter ftp server hostname or login details.
    FTP_USERNAME : Enter ftp username
    FTP_PASSWORD : Enter ftp user password
    FTP_UPLOAD_DIR : Enter backup location at ftp server.
    
    VERBOSE : Will show output on screen if enabled ( 1=enable, 0=disable )
    
    BACKUPDIR : Local backup directory
    TMPFILES : Temp files location
    
    SENDEMAIL : Enable/Disable email alerts ( 1=enable, 0=disable )
    EMAILTO : Email id
    
    Configure Cron for Daily Backup:

    Schedule a cron for daily backup, as per your preferred time.

    # crontab -l
    0 2 * * *  /bin/sh /etc/mydumpadmin/mysql-dump.sh
    
    MySQL Database Backup RPM
    Share. Facebook Twitter Pinterest LinkedIn Tumblr Email WhatsApp
    Previous ArticleFile Encryption using GPG Key Pair in Linux
    Next Article Linux RPM Comamnd with 10 Useful Examples

    Related Posts

    Most Effective Industry Specific Plug-ins for WordPress

    Updated:August 15, 20163 Mins Read

    How to Install Komodo Edit on Ubuntu 14.10, 14.04 LTS and 12.04 LTS via PPA

    1 Min Read

    Setup Database Mirroring in SQL Server 2012 with Certificates

    3 Mins Read

    How to Install XCache for PHP on CentOS,RHEL and Fedora

    2 Mins Read

    Setup Varnish on CentOS/RHEL 5/6 with Apache

    2 Mins Read

    Error in query (1548): Cannot load from mysql.proc. The table is probably corrupted

    1 Min Read

    1 Comment

    1. Mauro Miotello on May 8, 2014 7:28 am

      Hi, i’ve modified your script at line 38:
      ${MYSQLDUMP} –single-transaction -u….

      to avoid mysql err

      ps. what do you think about use of sftp instead ftp?

      Reply

    Leave A Reply Cancel Reply

    Recent Posts
    • What is the /etc/aliases file
    • What is the /etc/nsswitch.conf file in Linux
    • How to Install Ionic Framework on Ubuntu 22.04
    • What is the /etc/hosts file in Linux
    • How to Install Angular CLI on Ubuntu 22.04
    Facebook Twitter Instagram Pinterest
    © 2022 Tecadmin.net. All Rights Reserved | Terms  | Privacy Policy

    Type above and press Enter to search. Press Esc to cancel.