Ad Widget

Collapse

to take backup of Zabbix installtion

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • zz_yogesh
    Junior Member
    • May 2012
    • 2

    #1

    to take backup of Zabbix installtion

    One of my friend installed zabbix 1.8.9 and its running properly.Now i want to take the backup of installation as well as DB/config files to my PC. This will help to protect the config even from the machine failure.

    Can anyone help me out abt the procedure and locations where required file stored.

    Following are the setup details

    Zabbix: 1.8.9
    Platform:Red Hat Enterprise Linux Server release 5.4 (Tikanga)
    Database:MySQL
    SNMP Version:
    NET-SNMP version: 5.3.2.2


    Thanks
    Yogesh
  • HullZabbix
    Senior Member
    • Feb 2011
    • 104

    #2
    Just take a mySQL dump. Then take a copy of the following files:

    (assuming you have default 1.8.x locations)
    /etc/zabbix/zabbix_server.conf

    MySQL dump, fill in your user name and password, plus your database name (mine is zabbix), then your output location:

    mysqldump --user="usernamehere" --password="passwordhere" zabbix | gzip > /etc/zabbix/backup/zabbix.sql.gz


    To restore, run through the default zabbix install as you did originally (with the same version preferably), stop the zabbix service, overwrite the config. Then import the backup db with:

    extract the gzip'd backup

    mysql -h localhost -u usernamehere -p passwordhere < /etc/zabbix/backup/zabbix.sql

    Then you can start the zabbix server service and you should be back to normal.

    Comment

    • zz_yogesh
      Junior Member
      • May 2012
      • 2

      #3
      Hey AxidaZabbix

      Thanks for your quick reply.I will check .

      Yogesh

      Comment

      • Jairo
        Junior Member
        • Nov 2012
        • 2

        #4
        hi AxidaZabbix

        Originally posted by AxidaZabbix
        Just take a mySQL dump. Then take a copy of the following files:

        (assuming you have default 1.8.x locations)
        /etc/zabbix/zabbix_server.conf

        MySQL dump, fill in your user name and password, plus your database name (mine is zabbix), then your output location:

        mysqldump --user="usernamehere" --password="passwordhere" zabbix | gzip > /etc/zabbix/backup/zabbix.sql.gz


        To restore, run through the default zabbix install as you did originally (with the same version preferably), stop the zabbix service, overwrite the config. Then import the backup db with:

        extract the gzip'd backup

        mysql -h localhost -u usernamehere -p passwordhere < /etc/zabbix/backup/zabbix.sql

        Then you can start the zabbix server service and you should be back to normal.

        Is this applicable to version 2.0.3?
        I want to backup my zabbix with the conf and history data.
        and then when I make the restore, all be normal.


        Sorry my bad English.
        Jairo.

        Comment

        • HullZabbix
          Senior Member
          • Feb 2011
          • 104

          #5
          Originally posted by Jairo
          Is this applicable to version 2.0.3?
          I want to backup my zabbix with the conf and history data.
          and then when I make the restore, all be normal.


          Sorry my bad English.
          Jairo.
          Yes this will be fine with 2.0.3

          It shouldn't really make a difference as this is a mysql procedure.

          Comment

          Working...