Ad Widget

Collapse

Highly Available Zabbix Proxy

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • icerocks
    Junior Member
    • Oct 2020
    • 9

    #1

    Highly Available Zabbix Proxy

    Hi All,

    I'm testing Zabbix out and I'd like to find out what are the ways of implementing a Highly available Proxy. I am planning to monitor some 500 network devices (est. initial 400 NVPS) via SNMP. I am thinking that I will lose data when the proxy goes down so I would like to make sure that this doesn't happen.

    I found this blog about redundant proxies: https://blog.zabbix.com/how-to-setup...rations/12092/ but I'm not capable to write the script that switches the proxies as described on the blog. There are some guides about a highly available Zabbix Server but there are only a few about Proxies.
    Last edited by icerocks; 23-10-2020, 08:52. Reason: Adding some tags
  • icerocks
    Junior Member
    • Oct 2020
    • 9

    #2
    Cool. I was planning to use MariaDB for my proxies. I wonder if this kind of method will work.

    Comment

    • CharlieRoot
      Junior Member
      Zabbix Certified Specialist
      • Oct 2020
      • 15

      #3
      Originally posted by cyber
      Shortly, yes.
      We don't use separate DB, but Sqlite3 with its DB file on /dev/shm.. No need to deal with db replications etc.
      Corosync/pacemaker 8 node cluster for 6 proxies, split between 2 DC-s. If one side disappears, it all manages to run from 4 remaining hosts.. Switchover in seconds...
      I assume both proxy's running Corosync have the same hostname then? Active/Passive?

      Comment


      • gofree
        gofree commented
        Editing a comment
        I dont think its possible to achieve active/active configuration at the moment (?)
    • icerocks
      Junior Member
      • Oct 2020
      • 9

      #4
      Ah, I am thinking that I need to have the same hostname for all my proxies in the cluster. My worry with this one is that, when one of the proxies die, what happens to the collected data that was not committed to the Zabbix server once it becomes working and active again? Does it get automatically wiped out? Or does it need to have some manual intervention?

      Comment

      • CharlieRoot
        Junior Member
        Zabbix Certified Specialist
        • Oct 2020
        • 15

        #5
        Originally posted by icerocks
        Ah, I am thinking that I need to have the same hostname for all my proxies in the cluster. My worry with this one is that, when one of the proxies die, what happens to the collected data that was not committed to the Zabbix server once it becomes working and active again? Does it get automatically wiped out? Or does it need to have some manual intervention?
        Maybe I don't really understand what you mean, but each proxy has a unique name in principle. Only if you use an Active / Passive cluster via Corosync you will have to give those two Proxies the same name. During a failover, you may miss some data, depending on how high you set your timeout and how long the failover lasts.

        Comment

        • icerocks
          Junior Member
          • Oct 2020
          • 9

          #6
          Originally posted by CharlieRoot
          Maybe I don't really understand what you mean, but each proxy has a unique name in principle. Only if you use an Active / Passive cluster via Corosync you will have to give those two Proxies the same name. During a failover, you may miss some data, depending on how high you set your timeout and how long the failover lasts.
          Thank you. You're correct. I'm going to use an Active/Passive cluster via Corosync that is why I'm thinking of giving my Proxies the same hostname.

          Comment

          • icerocks
            Junior Member
            • Oct 2020
            • 9

            #7
            Originally posted by cyber
            Yes, data loss depends on how often you sync your data from proxy to server.
            Config for all proxies is present on all hosts in cluster, just each proxy runs at one host at a time. If something happens with host, there are some standby hosts, which take over the failed resources. Takes seconds to switch usually.
            Cool. So say, you have highly available proxies running thru pacemaker/corosync. How do you monitor them? I assume using the agent would be the best way for this but how do you go about passing the data over to the server? It is a bit tricky to configure the agent here since this is an Active/Passive setup and the cluster_ip and the zabbix-proxy service might move from one host to another.

            Comment

            • cyber
              Senior Member
              Zabbix Certified SpecialistZabbix Certified Professional
              • Dec 2006
              • 4807

              #8
              EDIT: My posts here are out of sequence due to human error and restoring of posts, try to fit them between other posts in thread, you should get a bit more clear picture.
              Technically, there should not be much difference, if its Server or Proxy. Proxy is a bit stripped down Server in essence.
              That blogpost seems more confusing than building a real cluster.. Seems to work for people, who are good codewriters. I would not like to update config of hundreds of hosts time to time... possibilities of failures seem too real. Better work out a real cluster with all those "complex" things like virtual IP-s etc.

              Comment

              • cyber
                Senior Member
                Zabbix Certified SpecialistZabbix Certified Professional
                • Dec 2006
                • 4807

                #9
                Shortly, yes.
                We don't use separate DB, but Sqlite3 with its DB file on /dev/shm.. No need to deal with db replications etc.
                Corosync/pacemaker 8 node cluster for 6 proxies, split between 2 DC-s. If one side disappears, it all manages to run from 4 remaining hosts.. Switchover in s...

                Comment

                • cyber
                  Senior Member
                  Zabbix Certified SpecialistZabbix Certified Professional
                  • Dec 2006
                  • 4807

                  #10
                  Yes, data loss depends on how often you sync your data from proxy to server.
                  Config for all proxies is present on all hosts in cluster, just each proxy runs at one host at a time. If something happens with host, there are some standby hosts, which take over the failed resources. Takes seconds...

                  Comment

                  • cyber
                    Senior Member
                    Zabbix Certified SpecialistZabbix Certified Professional
                    • Dec 2006
                    • 4807

                    #11
                    If you have not tied your agent to use only specific IP, it should listen on all available ones, so you can turn to it either by its real IP or the proxy VIP. Configure a host, where agent interface points to proxy VIP and polled by proxy itself ( I guess you can poll directly from server also, if you decide so). Passive items. Which ever host is running a proxy at the moment, will answer.

                    Comment

                    • alz0
                      Junior Member
                      • Feb 2023
                      • 21

                      #12
                      Is there any other way to achieve this availability in the proxies? Or the only way is having a coro/pace active-passive cluster?

                      Comment

                      Working...