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. mysql query for object status (with grafana)

mysql query for object status (with grafana)

Scheduled Pinned Locked Moved Support
2 Posts 2 Posters 10.6k 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.
  • R
    R
    reez_q11
    wrote on last edited by
    #1

    hi,

    i'm testing querying object status on database (mysql) with grafana. so i can put some dashboard on grafana. but seems the object status on the database isn't valid. i had already test it with 2 netxms server. do you know how i can read object status from database? what am i missing?

    thx.

    on console (valid):

    on grafana query (not valid):

    mysql query:

    select
      o.name,
      net.service_type,
      node.name as `node`,
      case
          when poller.name is null then "default (netxms server)"
          else poller.name
      end as `poller`,
      ip_port as `tcp port`,
      o.`status` as c
    from object_properties o
      inner join network_services net on o.object_id = net.id
      inner join object_properties node on net.node_id = node.object_id
      left join object_properties poller on net.poller_node_id = poller.object_id
    where
      o.`status` <> 6


    2018-02-21_152858.png

    2018-02-21_152406.png

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

      Hi,

      server only updates object_properties table when something persistent changes (like object name) and on shutdown (to save status and other runtime information). On large installations it removes a lot of unnecessary DB updates.

      Best regards,
      Victor

      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