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. How to Count/Graph/Check TCP connection States Table with NetXMS, ...

How to Count/Graph/Check TCP connection States Table with NetXMS, ...

Scheduled Pinned Locked Moved Support
1 Posts 1 Posters 25.1k 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.
  • S
    S
    sodalist
    wrote on last edited by
    #1

    Useful for:

    • monitoring number of connections to specific TCP port
    • checking if service is listening on specific port
    • statistics of TCP connections table
    • checking load on specific service as number of connections
    • detecting TCP connection state based attacks and abnormalities

    Requirements:

    • agent on *nix system with net-snmp tools
    • bash,grep,cat,snmpnetstat

    Links:
    http://net-snmp.sourceforge.net/docs/man/snmpnetstat.html
    snmp_stat.sh attached

    How-to:
    1.
    configure agent on node that has snmp connection to nodes you want to monitor:
    ExternalParameter = TCP.Connections(*):/opt/netxms/scripts/snmp_stat.sh $1 $2 $3 $4

    add nodes you want to monitor to trusted nodes on that node

    parameters:
    # $1 = hostname, monitored node ip
    # $2 = community, monitored node snmp community string
    # $3 = TCP state {ESTABLISHED|LISTEN|TIMEWAIT|TIMECLOSE|FINWAIT1|FINWAIT2|SYNSENT|SYNRECV}
    # $4 = TCP port for detailed {ESTABLISHED|LISTEN}

    configure DCI's on node you want to monitor and specify node from 1.
    as proxy node when creating DCI

    1. examples DCI's:

    # all established connections
    TCP.Connections(192.168.1.1,public,ESTABLISHED)

    # all established connections to TCP port 80
    TCP.Connections(192.168.1.1,public,ESTABLISHED,80)

    # will return 1 if service is listening on TCP port 25
    TCP.Connections(192.168.1.1,public,LISTEN,25)

    Feel free to use. Suggestions, spelling 🙂 and bug fixes welcome.

    Ales


    snmp_stat.sh

    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