Page 1 of 1
File download Using NRPE
Posted: Thu Jun 16, 2016 7:07 am
by harsha.s.aryan
Hi,
is there any plugin where i can download a file from every nagios clients (NRPE).
Harsha S
Re: File download Using NRPE
Posted: Thu Jun 16, 2016 8:04 am
by eloyd
Not really. NRPE is a protocol that allows Nagios to request information from an NRPE agent running on a remote server, and return a Nagios plugin result. Those results are typically short, one line output designed to be used in a page or SMS text message for alerts. They are not files. Also, Nagios is a monitoring tool, not a file management tool, so having it download a file would take time, and Nagios may prematurely terminate the connection because it takes too much time - or at least, more time than it thinks that a service check should take.
So the bottom line is that if you are looking to transfer files, Nagios is not a good tool for that, and NRPE is just a communications protocol, not a file transfer mechanism.
Re: File download Using NRPE
Posted: Thu Jun 16, 2016 8:19 am
by harsha.s.aryan
this is not exactly for file transfer
i have a script and the output is more than 10 lines but in nrpe output is not coming completely.
is there any way to get the output of the complete file
Re: File download Using NRPE
Posted: Thu Jun 16, 2016 8:36 am
by eloyd
My first question would be, do you really need to capture all that output? My second question would be, can you use a different plugin?
NRPE has a limitation on the number of characters it will send back, so it's likely that you will not be able to do what you need with NRPE. Remember, Nagios plugin outputs are supposed to be short and concise.
Re: File download Using NRPE
Posted: Thu Jun 16, 2016 8:56 am
by harsha.s.aryan
yes i want to capture complete the output.
is there any other way where i can capture the complete output. or what is the max output NRPE can provide
Re: File download Using NRPE
Posted: Thu Jun 16, 2016 9:04 am
by eloyd
Can you share what the plugin does and what the output is supposed to be? This might help us better understand what you are trying to do.
Re: File download Using NRPE
Posted: Thu Jun 16, 2016 9:10 am
by harsha.s.aryan
its not a plugin,
its a script which will check all users in linux and give the status of all users.
if needed i will share the script
Re: File download Using NRPE
Posted: Thu Jun 16, 2016 10:09 am
by lmiltchev
i have a script and the output is more than 10 lines but in nrpe output is not coming completely.
is there any way to get the output of the complete file
Outputting more than 10 lines shouldn't be an issue...
On the client:
On the Nagios server:
Code: Select all
[root@localhost libexec]# ./check_nrpe -H x.x.x.x -c catfile
This is line 1
This is line 2
This is line 3
This is line 4
This is line 5
This is line 6
This is line 7
This is line 8
This is line 9
This is line 10
This is line 11
[root@localhost libexec]#
The question should be
how many characters are you trying to output?
Re: File download Using NRPE
Posted: Thu Jun 16, 2016 10:39 am
by harsha.s.aryan
output may come max up to 2000 char will it work?
Re: File download Using NRPE
Posted: Thu Jun 16, 2016 3:20 pm
by hsmith
I believe we are limited to 1024 characters right now. We have a version coming out that should resolve this in the future. If you're interested, check it out here:
https://github.com/NagiosEnterprises/nr ... pe-3.0-RC2
Please note that the amount of support we can provide for a RC version is very limited, and if you believe you find a bug/issue, you should post it on the GitHub page.