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. Monitoring FTP daemon[Solved]

Monitoring FTP daemon[Solved]

Scheduled Pinned Locked Moved Support
4 Posts 2 Posters 34.5k 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.
  • B
    B
    BlackMamba
    wrote on last edited by
    #1

    Hello everybody!

    I'm a new NetXMS user (very noob) and I'm sorry if the question has been already made, but I was unable to find an answer.

    My goal is to monitor a FTP daemon (in particular, I'm using vsftpd) using NetXMS. My configuration is:

    a) NetXMS server+agent installed on a virtual machine with Debian and only with the command line
    b) NetXMS agent installed on a local machine (Xubuntu) where I have my FTP daemon installed and which I use to connect to the NetXMS client through web interface or Management Console.

    I have this strange configuration only because I'm testing my skills, and I'm trying to "learn" NetXMS.

    So, I've tried to monitor the FTP daemon using similar passages of this tutorial http://wiki.netxms.org/wiki/How_to_send_e-mail_notification_when_disk_space_is_low but I haven't been able to set up the right value on Data-Parameter in the general voice of the DCI.
    Now my questions are:

    1. What should I put on the Parameter voice in the DCI configuration window?
    2. Is there an easiest, or righter, method to monitor a FTP daemon? If yes, could someone please explain me this method?

    Thanks to all for the support!

    1 Reply Last reply
    0
    • B
      B
      BlackMamba
      wrote on last edited by
      #2

      I did it!
      The answer to my question (1) is: Process.Count(vsftpd). Then I set the threshold to "=0" so the agent verifies the process count and if the daemon is stopped (or down for any reason) the DCI has 0 as value and the alarm is raised. I know that it isn't a very smart solution, but at least it works!
      Unfortunately I didn't figure out a easier way. If someone would like to answer to my question (2), he is welcome!

      Now I have another question. I'd like to verify not only that the daemon is running, but also that the service is working. To do this, I need to connect somehow to the FTP server and verify the reply I obtain after a login attempt. Or just read the answer of the connection attempt. Is it possible to do something like that using NetXMS, possibly using the agent in the local machine (the one where I also have the FTP daemon running)?

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

        Hi!

        You can use portcheck subagent to check that network service is actually responds. There is short documentation: http://wiki.netxms.org/wiki/Subagent:PortCheck. There are no FTP support, so you can only check that TCP connection can be established.

        Another option is to define external parameter on one of the agents to connect and check FTP server. It could be something like this:

        ExternalParameter = FTP.Status(*):echo quit | nc -q1 $1 21 | grep '^220 .*' | wc -l
        

        After you add this line to nxagentd.conf and restart agent, it will provide new paraneter FTP.Status, which will take server DNS name or IP address as argument, and return 1 if 220 got in response, and 0 otherwise.

        Best regards,
        Victor

        1 Reply Last reply
        0
        • B
          B
          BlackMamba
          wrote on last edited by
          #4

          @victor said in Monitoring FTP daemon[Solved]:

          Hi!

          You can use portcheck subagent to check that network service is actually responds. There is short documentation: http://wiki.netxms.org/wiki/Subagent:PortCheck. There are no FTP support, so you can only check that TCP connection can be established.

          Yes, I did something similar. I just used ServiceCheck.Custom(IPserverFTP, 21) and the threshold is "=0". So, till I get 0 by the agent, the port 21 is open and then the service is up; once I get 1 the service is down and the alarm is raised.

          @victor said in Monitoring FTP daemon[Solved]:

          Another option is to define external parameter on one of the agents to connect and check FTP server. It could be something like this:

          ExternalParameter = FTP.Status(*):echo quit | nc -q1 $1 21 | grep '^220 .*' | wc -l
          

          After you add this line to nxagentd.conf and restart agent, it will provide new paraneter FTP.Status, which will take server DNS name or IP address as argument, and return 1 if 220 got in response, and 0 otherwise.

          Best regards,
          Victor

          This solution is much smarter and works with the same logic of the first one. So, I'm twice happy: my ideas where right and I obtain also a better solution. Many thanks 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