FTP File Monitoring

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
gsd_pe
Posts: 7
Joined: Tue Mar 25, 2014 2:18 am

FTP File Monitoring

Post by gsd_pe »

Hi,

Is there a way the Nagios XI has the capability to check and notify when a file is changed on a Anonymous FTP server.
The bottom line is Nagios needs to monitor a anonymous FTP portal for file changes and notify accordingly.

Thanks
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

Re: FTP File Monitoring

Post by slansing »

I would definitely advise searching for your specific FTP server, or for a specific task you want to do or check on the exchange:

http://exchange.nagios.org/

If you are just checking a file there are loads of integrity/change plugins there such as:

http://exchange.nagios.org/index.php?op ... 20modified
gsd_pe
Posts: 7
Joined: Tue Mar 25, 2014 2:18 am

Re: FTP File Monitoring

Post by gsd_pe »

I think my question is not properly understood.

I want to get notified when a file gets changed on a anonymous FTP portal.
Also note that I am not the one who controls or has access to the server running FTP service.

A quick example for monitoring an ISO file
--------------------------------------------------
The Anonymous FTP portal I need nagios to monitor is ftp://ftp.freebsd.org/pub/FreeBSD/relea ... MAGES/9.2/
Now when ever the file "FreeBSD-9.2-RELEASE-i386-dvd1.iso" changes in the above FTP URL, I need to get a notification.
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: FTP File Monitoring

Post by abrist »

If you have ssh access or the ability to install an agent on the server, you could use a file_age plugin to check the file. But as of now, I did not see an ftp plugin that chacks file age. You may be able to alter one of the ftp plugins on the exchange to your purpose:
http://exchange.nagios.org/index.php?op ... chword=ftp
Or you may need to create a custom shell script to do what you need.
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
technick
Posts: 49
Joined: Tue Feb 04, 2014 10:30 am
Location: Denver, CO

Re: FTP File Monitoring

Post by technick »

This might not be the most efficient way of solving this problem but it would work, none the less and it assumes a level of scripting proficiency...

Have a script that auto logins to the anonymous ftp and does an extended ls on the specific file and redirects the output of the session to a temporary file on the nagios xi server. Create your check to parse that temporary file for the data and do an operation on the date and depending on that, it would have different exit code status.

Check out the guidelines below

https://nagios-plugins.org/doc/guidelines.html

Hope this helps...

Cheers
----------------------
Nagios Jedi in training.
Locked