NCPA listener timing out on LDAP enabled RHEL servers

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
meganwilliford
Posts: 101
Joined: Tue Aug 06, 2019 7:49 am

NCPA listener timing out on LDAP enabled RHEL servers

Post by meganwilliford »

We are running into an issue when installing ncpa 2.1.7 on RHEL servers. This exact issue which says was resolved in 2.1.7: https://github.com/NagiosEnterprises/ncpa/issues/523.

We have the below set in the config file but it is still walking the NFS mounted filesystem:
exclude_fs_types = aufs,autofs,binfmt_misc,cifs,cgroup,configfs,debugfs,devpts,devtmpfs,encryptfs,efivarfs,fuse,fusectl,hugetlbfs,mqueue,nfs,overlayfs,proc,pstore,rpc_pipefs,securityfs,selinuxfs,smb,sysfs,tmpfs,tracefs

The NCPA installs, but cannot start the listener. The listener is walking the NFS mounted filesystem and it looks like it runs as root which has no privileges in the remote filesystems. It sees a directory entry and tries to get to that file or directory, not sure which, and cannot see it. After about 5 minutes of walking the tree the listener dies.
There must be a way to config ncpa to NOT walk the tree or at least not walk remote filesystem tree.
We have a lot of servers with over 320 remote mounts and some with over a 1000.
The first thing it does is attempt to create a group called nagios, and most of these systems are LDAP enabled, so it attempts to create the group in LDAP, which fails.

Are there any other workarounds to this?
meganwilliford
Posts: 101
Joined: Tue Aug 06, 2019 7:49 am

Re: NCPA listener timing out on LDAP enabled RHEL servers

Post by meganwilliford »

Example of errors from log of when listener is trying to start:

Aug 8 14:16:28 <servername> ncpa_passive: ERROR:root:[Errno 2] No such file or directory: '/net/...
Aug 8 14:16:28 <servername> ncpa_passive: Traceback (most recent call last):
Aug 8 14:16:28 <servername> ncpa_passive: File "/root/ncpa/agent/listener/psapi.py", line 59, in make_mountpoint_nodes
Aug 8 14:16:28 <servername> ncpa_passive: OSError: [Errno 2] No such file or directory: '/net/...
Aug 8 14:16:32 <servername> ncpa_listener: ERROR:root:[Errno 2] No such file or directory: '/net/...
Aug 8 14:16:32 <servername> ncpa_listener: Traceback (most recent call last):
Aug 8 14:16:32 <servername> ncpa_listener: File "/root/ncpa/agent/listener/psapi.py", line 59, in make_mountpoint_nodes
Aug 8 14:16:32 <servername> ncpa_listener: OSError: [Errno 2] No such file or directory: '/net/...
Aug 8 14:16:35 <servername> ncpa_passive: ERROR:root:[Errno 2] No such file or directory: '/net/...
Aug 8 14:16:35 <servername> ncpa_passive: Traceback (most recent call last):
Aug 8 14:16:35 <servername> ncpa_passive: File "/root/ncpa/agent/listener/psapi.py", line 59, in make_mountpoint_nodes
Aug 8 14:16:35 <servername> ncpa_passive: OSError: [Errno 2] No such file or directory: '/net/...
Aug 8 14:16:35 <servername> ncpa_listener: ERROR:root:[Errno 2] No such file or directory: '/net/...
Aug 8 14:16:35 <servername> ncpa_listener: Traceback (most recent call last):
Aug 8 14:16:35 <servername> ncpa_listener: File "/root/ncpa/agent/listener/psapi.py", line 59, in make_mountpoint_nodes
Aug 8 14:16:35 <servername> ncpa_listener: OSError: [Errno 2] No such file or directory: '/net/...
Aug 8 14:16:35 <servername> ncpa_listener: ERROR:root:[Errno 2] No such file or directory: '/net/...
Aug 8 14:16:35 <servername> ncpa_listener: Traceback (most recent call last):
Aug 8 14:16:35 <servername> ncpa_listener: File "/root/ncpa/agent/listener/psapi.py", line 59, in make_mountpoint_nodes
Aug 8 14:16:35 <servername> ncpa_listener: OSError: [Errno 2] No such file or directory: '/net/...
User avatar
cdienger
Support Tech
Posts: 5045
Joined: Tue Feb 07, 2017 11:26 am

Re: NCPA listener timing out on LDAP enabled RHEL servers

Post by cdienger »

Please provide a copy of the ncpa.cfg file as well as the output of these commands run on a RHEL server where you're seeing this behavior:

Code: Select all

python
>>> import psutil
>>> psutil.disk_partitions(all=True)
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
meganwilliford
Posts: 101
Joined: Tue Aug 06, 2019 7:49 am

Re: NCPA listener timing out on LDAP enabled RHEL servers

Post by meganwilliford »

Thanks for replying. I sent a private message with the output and config file.
User avatar
cdienger
Support Tech
Posts: 5045
Joined: Tue Feb 07, 2017 11:26 am

Re: NCPA listener timing out on LDAP enabled RHEL servers

Post by cdienger »

I've not been able to reproduce the issue with the configuration provided or otherwise. What log are you seeing these messages in exactly?

Install the psutil module and try running the psutil.disk_partitions(all=True) command again:

Code: Select all

yum install python-pip
pip install psutil
python
import psutil
psutil.disk_partitions(all=True)
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Locked