Problems With NRDP Clients - Windows and Mac

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
TCN-Link
Posts: 30
Joined: Tue Dec 13, 2016 2:05 pm

Problems With NRDP Clients - Windows and Mac

Post by TCN-Link »

Hello, all.

I'm having a couple of problems with the NRDP clients (passive checks using NRDS configurations and NRDP for inbound transfers). One problem is specific to Windows, the other is specific to macOS/Mac OS X.

In Windows:
There is initial communication and the proper codes and messages are sent to the XI server in subsequent checks but the Scheduled Task isn't working. Although the task is supposed to be run by SYSTEM (which has Full Control permissions) and it doesn't help to adjust it to run with the highest permissions, the script it calls, C:\Program Files\Nagios\NRDS_Win\NRDS_Win.vbs, will only run properly if it's run manually from the command line as an administrator. There's a permissions problem and I'm not sure 1. how to fix it and 2. why it installed and set up this way. This is true for both 32-bit and 64-bit versions.

In macOS/Mac OS X:
Checks go the XI server and at regular intervals. The cron job seems to be working. The problem is it doesn't use any of the plugin scripts properly. When I run these scripts in Terminal individually, they run, pick up on what they need to, then give the appropriate exit code. When the NRDP client runs and tries to send to the server, it only submits the custom messages and OK status (exit code 0). I have a feeling the client isn't running the scripts properly. The scripts are made in Python and AppleScript, so the kind of script seems to be of little consequence.

Any advice?

Thank you,
~ Link
User avatar
mcapra
Posts: 3739
Joined: Thu May 05, 2016 3:54 pm

Re: Problems With NRDP Clients - Windows and Mac

Post by mcapra »

I'll only push this once, but NCPA might be a better option for handling passive checks. The NRDS clients we distribute are a bit dated. NCPA 2.1 will be able to accept NRDS configurations and will probably replace the NRDS clients in the long term. I would suggest reviewing NCPA to see if it fits your needs:
https://www.nagios.org/ncpa/

I've been unable to replicate the Windows issues on my test Server 2012 machine. Are you certain you ran the installer as an administrator? I believe it's required by default, but I could be wrong. Other than that, my next thought is that perhaps UAC is blocking the script's execution.

For the Mac setup, can you share the NRDS config file (client-side) being leveraged? We don't have a Mac to test against on-site unfortunately, but we'll do our best to work through the problem.
Former Nagios employee
https://www.mcapra.com/
TCN-Link
Posts: 30
Joined: Tue Dec 13, 2016 2:05 pm

Re: Problems With NRDP Clients - Windows and Mac

Post by TCN-Link »

I appreciate the suggestion.

We've tried NCPA before, but it didn't seem to work. It seems to rely on having computers on the same network. We're monitoring all remote clients with absolutely no centralized network, VPN, or infrastructure. We're an entirely remote based company; everyone we're monitoring is simply using their own home Internet connections. It was previously suggested by Nagios support that we use NRDP because of this.

I'll try reinstalling the Windows client, making sure it's installed as an administrator (I forget if this was done previously).

I've attached the NRDS.cfg file for Mac.

Thanks much!
You do not have the required permissions to view the files attached to this post.
User avatar
mcapra
Posts: 3739
Joined: Thu May 05, 2016 3:54 pm

Re: Problems With NRDP Clients - Windows and Mac

Post by mcapra »

TCN-Link wrote:It was previously suggested by Nagios support that we use NRDP because of this.
NCPA is pretty good at speaking NRDP, which is why I recommended it. It's not exclusively used for active checks, and in this case I think it would be beneficial since we can do some much richer troubleshooting when everything occurs in python. The only downside is NCPA can't currently support NRDS configurations (though it will in the future), so if your plugins get updated it won't get pushed to all the machines. More info about NCPA in general:
https://assets.nagios.com/downloads/ncp ... g_NCPA.pdf

Specifically using NCPA to talk to an NRDP server:
https://www.nagios.org/ncpa/help/2.0/passive.html

Would it be possible for you to share some of the scripts that this Mac machine is trying to execute? That's the only thing I can think of right now that might be different between your machine and our lab machine.
Former Nagios employee
https://www.mcapra.com/
TCN-Link
Posts: 30
Joined: Tue Dec 13, 2016 2:05 pm

Re: Problems With NRDP Clients - Windows and Mac

Post by TCN-Link »

Sure. Here are the scripts the Mac is using.
You do not have the required permissions to view the files attached to this post.
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: Problems With NRDP Clients - Windows and Mac

Post by ssax »

Edit the scheduled task, click the Actions tab, and edit the Action, what do you have set for all those options? Also, send a screenshot of the Settings tab as well.

What version of OSX are you using?


Thank you
TCN-Link
Posts: 30
Joined: Tue Dec 13, 2016 2:05 pm

Re: Problems With NRDP Clients - Windows and Mac

Post by TCN-Link »

Mac:
The instance of macOS being tested is macOS Sierra (10.12.3). I've removed and reinstalled the NRDP client. Still nothing comes up in Unconfigured Objects on the XI server.
By the way, the instructions provided by the NRDS Config Manager to install the client are incorrect. It asks that we use wget to download the zipped installation. The wget command is not included with macOS/Mac OS X. Instead, you have to use curl.


Windows:
Here are screenshots for what's in the Actions and Settings tabs.
NRDP Windows - Scheduled Tasks Screenshots.zip
I reinstalled the NRDP client for Windows as an administrator. First run, it reaches out to the server, grabbed about a third of the scripts from the server, and then stopped. Each subsequent scheduled run doesn't appear to do anything. The machine does not ever come up in Unconfigured Objects. I've attached the log file so you can see what's happening; it's as if it tried to download, stopped but made an entry a script it tried to download but didn't, and now it's trying to reference a script without even trying to fetch it. Now, running the VBScript manually doesn't even work properly anymore.
NRDS_Debug.log
So, I tried installing the NCPA as previously suggested. When I installed it manually, it didn't ask me for an NRDS Config like the previously provided indicates. In fact, the screenshots in the document provided in this thread didn't any match the windows I saw at all. So, all NCPA is doing is taking up drive space. I attached those screenshots in a ZIP file here and here's an explanation of what I did when I came across them.
  • I wasn't familiar with what it was asking for, there was no indication of these settings specifically on the XI server, so I left everything alone and clicked Next.
  • I put all of the NRDS information it asked for and enabled passive checks here. Nowhere here does it ask for the NRDS Config.
  • I had no pre-setup checks. However, so I could see if there was any server communication, I left the first couple of lines. I removed the selected lines as we don't own any of the machines we're monitoring and I need to install it as if it were another contractor's computer.
  • I left this as it was.
NCPA Install Windows Screenshots.zip
You do not have the required permissions to view the files attached to this post.
TCN-Link
Posts: 30
Joined: Tue Dec 13, 2016 2:05 pm

Re: Problems With NRDP Clients - Windows and Mac

Post by TCN-Link »

Mac:
It seems the NRDP client for Mac isn't even downloading the scripts from the server like it should.
Screen Shot 2017-02-24 at 10.02.36 PM.jpg
CentOS Server:
Here are two screenshots of the scripts in their locations respective to their intended client operating systems.
Screen Shot 2017-02-24 at 10.05.45 PM.jpg
Screen Shot 2017-02-24 at 10.05.08 PM.jpg
You do not have the required permissions to view the files attached to this post.
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: Problems With NRDP Clients - Windows and Mac

Post by ssax »

I've created a bug report for the wget -> curl issue:

Code: Select all

Task Detail: Nagios XI Bug Report: NRDS Config Manager - Client Install Instructions when choosing OSX uses wget, should use curl
I'm going to lab this up to see what the issue is, I'm not sure where NCPA actually fully supports NRDS/updating configs/plugins and the NCPA dev is out today so I can't ask him, I'll let you know what he says when he's back.
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: Problems With NRDP Clients - Windows and Mac

Post by ssax »

Also, for your screenshot of the scheduled task actions page, please edit the scheduled task, click the actions tab, and then click the Edit button and send a screenshot of that page.
- Include the full "Start in" text as well so that I can make sure it's proper.

When viewing the scheduled task, scroll over to the right, what does the Last Run Result say?

Thank you
Locked