Ad Widget

Collapse

zabbix_sender, zabbix-proxy and not persisten net connection

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • jancs
    Member
    • Jul 2014
    • 30

    #1

    zabbix_sender, zabbix-proxy and not persisten net connection

    Hi!

    What could be the right solution for such "setup": there is a remote computer gathering various data which are submitted to Zabbix server using zabbix_sender. The specific is such that there is no persistent net connection, so it has to gather data mainly offline and send them to the server when the connection is available.

    Can I use zabbix-proxy for such solution? I know I can, but I am not sure in some details:
    -will it be able to understand on its own when the connection is live?
    -regarding data - do I have to to add the time stamp to each record submitted to proxy in order to keep data ordered?
    -do I have to process such timestamps somehow at the server end?

    Janis
  • ingus.vilnis
    Senior Member
    Zabbix Certified Trainer
    Zabbix Certified SpecialistZabbix Certified Professional
    • Mar 2014
    • 908

    #2
    Hi Janis,

    In your scenario proxy will be a good solution. Just make sure your proxy is running all the time. And then send the data from sender to proxy.

    Proxy will automatically understand when the connection is live or not. It attempts to connect to Zabbix server every minute. When it fails to connect, it buffers the collected data in its internal database.

    You don't have to add any timestamps to your data because proxy autmatically saves the data with timestamp when the value was received. Also from Zabbix sender.

    No additional processing of timestamps are required on Zabbix server side.

    When you install your proxy, check the zabbix_proxy.conf file carefully. Set the ProxyOfflineBuffer= setting to somewhat longer than you usually have your network outages. Maximum here is 720 hours (30 days). Default setting is 1 hour. Proxy will buffer the data for this amount of time if Zabbix server is not accessible.

    Best Regards,
    Ingus

    Comment

    • jancs
      Member
      • Jul 2014
      • 30

      #3
      Thank you for clarification!

      One additional issue arose - if during the time for the connection being off-line the proxy server resets/restarts, does it lose all accumulated and not-yet-transfered data?

      My current in-vivo experiments seems confirming such a grave scenario.

      Janis

      Comment

      • ingus.vilnis
        Senior Member
        Zabbix Certified Trainer
        Zabbix Certified SpecialistZabbix Certified Professional
        • Mar 2014
        • 908

        #4
        Hi Janis,

        In normal operation proxy never should lose any data in case of restart while being offline. All collected data is stored in proxy database which is stored on disk and not in RAM for current running process.

        Can you tell more details about the test proxy setup you are having?

        Best Regards,
        Ingus

        Comment

        • jancs
          Member
          • Jul 2014
          • 30

          #5
          Everything is working as you described.

          The setup is Raspberry PI + GSM modem setting up a broadband connection once per hour for 5 min, during which the accumulated data are transmitted to Zabbix server.

          It could be interesting to have an option to communicate between proxy and server using just SMSes (or info transfer over phone line using DTMF signals).

          While there isn't, I'll have to implement it outside Zabbix.

          Janis

          Comment

          Working...