Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (Flatly)
  • No Skin
Collapse
Brand Logo

NetXMS Forum

  1. Home
  2. Support
  3. NetXMS in a cluster mode

NetXMS in a cluster mode

Scheduled Pinned Locked Moved Support
5 Posts 2 Posters 29.4k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • G
    G
    Genady
    wrote on last edited by
    #1

     Hi,
    I try configuring NetXMS in a cluster ( or HA) mode.
    Could you, please clarify whether it possible or not? if not,  do you have any plans adding cluster/HA support for NetXMS installation?

    Thanks,
    Genady

    1 Reply Last reply
    0
    • V
      V
      Victor Kirhenshtein
      wrote on last edited by
      #2

      Hi!

      It is possible to create active-passive cluster using any clustering software, like Heartbeat or Microsoft Cluster. As NetXMS server stores all configuration in database, and configuration file contains almost only information necessary to connect to database, you just need to ensure database availability (by using replication or clustering software) and configure cluster software to start netxmsd. You also will need to add addresses of both cluster nodes to agents configuration files, because even if you are using virtual IP, outgoing connections will be made from primary addresses on the nodes.
      I have NetXMS HA solution based on Heartbeat and DRBD (with database residing on shared DRBD device), and it works without problems for more than a year now. I can post configuration files for this configuration if it will help.

      Best regards,
      Victor

      1 Reply Last reply
      0
      • G
        G
        Genady
        wrote on last edited by
        #3

        Hi Victor,
        Thanks a lot for reply.
        It would be great if you can post the cluster config files.

        Thanks,
        Genady

        1 Reply Last reply
        0
        • V
          V
          Victor Kirhenshtein
          wrote on last edited by
          #4

          Hi!

          I have two Debian Linux nodes called netxms-1 (10.0.0.11) and netxms-2 (10.0.0.12) with heartbeat and DRBD. Database engine is PostgreSQL, with database on shared disk. There are also virtual IP 10.0.0.10 used for client connection. Configuration files looks like following:

          /etc/ha.d/ha.cf

          keepalive 1
          deadtime 5
          warntime 3
          initdead 20
          bcast eth0
          bcast eth1
          auto_failback no
          node netxms-1
          node netxms-2
          crm no
          

          /etc/ha.d/haresources

          netxms-1 IPaddr::10.0.0.10/24 drbddisk::netxmsdb Filesystem::/dev/drbd0::/postgresql::reiserfs postgresql-8.3 netxmsd
          

          /etc/drbd.conf

          global {
                  usage-count no;
          }
          
          common {
                  syncer {
                          rate 10M;
                  }
          }
          
          resource netxmsdb {
                  protocol B;
                  handlers {
                          pri-on-incon-degr "echo o > /proc/sysrq-trigger ; halt -f";
                          pri-lost-after-sb "echo o > /proc/sysrq-trigger ; halt -f";
                          local-io-error "echo o > /proc/sysrq-trigger ; halt -f";
                          # outdate-peer "/usr/lib/heartbeat/drbd-peer-outdater -t 5";
                  }
          
                  startup {
                          wfc-timeout 0;
                          degr-wfc-timeout 120;
                  }
          
                  disk {
                          on-io-error   detach;
                  }
          
                  net {
                          cram-hmac-alg "sha1";
                          shared-secret "*********";
                          after-sb-0pri disconnect;
                          after-sb-1pri disconnect;
                          after-sb-2pri disconnect;
                          rr-conflict disconnect;
                  }
          
                  syncer {
                          al-extents 257;
                  }
          
                  on netxms-1 {
                          device /dev/drbd0;
                          disk /dev/sdb;
                          address 10.10.10.1:7788;
                          meta-disk  internal;
                  }
          
                  on netxms-2 {
                          device /dev/drbd0;
                          disk /dev/sdb;
                          address 10.10.10.2:7788;
                          meta-disk internal;
                  }
          }
          

          /etc/netxmsd.conf

          DBDriver = /usr/lib/libnxddr_pgsql.so
          DBServer = 127.0.0.1
          DBName = netxms_db
          DBLogin = netxms
          DBPassword = ******
          LogFailedSQLQueries = yes
          LogFile = /var/log/netxmsd
          

          File /etc/postgresql/8.3/main/postgresql.conf is quite big, so I don't see any reason to put it here entirely. The only non-default setting there is

          data_directory = '/postgresql/main'
          

          PostgreSQL and netxmsd removed from auto-start, as they should be started by heartbeat.

          Each node has NetXMS agent running instantly. Agent's configuration file looks like following:

          MasterServers = 127.0.0.1, 10.0.0.11, 10.0.0.12
          LogFile = /var/log/nxagentd
          FileStore = /tmp
          SubAgent = /usr/lib/libnsm_portCheck.so
          

          Note that IP addresses of both nodes listed in MasterServers parameter.

          Best regards,
          Victor

          1 Reply Last reply
          0
          • G
            G
            Genady
            wrote on last edited by
            #5

            Thanks a lot Victor,
            I will give it a try

            Genady

            1 Reply Last reply
            0

            Hello! It looks like you're interested in this conversation, but you don't have an account yet.

            Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

            With your input, this post could be even better 💗

            Register Login
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            Powered by NodeBB Contributors
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • Users
            • Groups