Page 1 of 4
showmount: Program not registered
Posted: Wed Sep 26, 2018 11:35 am
by shamrozkadiwal
I have nagios core 3.3.1 installed and setup NFS monitoring which is throwing this alert "showmount: RPC: Program not registered ". I am not quite sure what to check. However, I did google it and all pointed to restart nfs, nfslock, and rpc service which i did and didn't resolve the issue. Client is running on the Centos 5. Please let me know if anybody has any suggestion.
Re: showmount: Program not registered
Posted: Wed Sep 26, 2018 1:17 pm
by mcapra
Can you share the full Nagios service definition associated with the "NFS" service on host "awhu013a"?
Can you also share copies of any scripts/plugins supporting the check_command parameter under the "NFS" service definition?
This sounds like some sort of systemd/initd problem related to the nfs system service on this machine. Not exactly a Nagios Core related problem.
Re: showmount: Program not registered
Posted: Thu Sep 27, 2018 9:14 am
by lmiltchev
Any updates @shamrozkadiwal?
Re: showmount: Program not registered
Posted: Thu Sep 27, 2018 9:32 am
by shamrozkadiwal
Please bear with me and I will shortly post the service and host definition associated with the NFS. However, my other servers are reporting the NFS just fine. This is the only one which is throwing UNKNOWN error.
Re: showmount: Program not registered
Posted: Thu Sep 27, 2018 9:55 am
by lmiltchev
Whenever you are ready.
Re: showmount: Program not registered
Posted: Fri Sep 28, 2018 11:14 am
by shamrozkadiwal
Command
Code: Select all
# Check if the NFS server is running (version 2 and version 3)
define command{
command_name check-nfs
command_line $USER1$/check_rpc -H $HOSTADDRESS$ -C nfs -c2,3
}
Hostgroup
Code: Select all
define hostgroup{
hostgroup_name linux-vm-servers
alias Virtual Linux Servers
}
define hostgroup{
hostgroup_name linux-web-servers
alias Linux Web Servers
}
Host
Code: Select all
define host{
host_name awhu013a
hostgroups linux-vm-servers,linux-web-servers
alias awhu013a
address X.X.X.X
use generic-web
notification_period work-hours
}
Service
Code: Select all
define service{
use generic-24x7-email
hostgroup_name linux-web-servers
servicegroups data-services
service_description NFS
check_command check_nfs
normal_check_interval 360
}
I got this
I got this when I ran the below command from the nagios server.
shamroz@nagios /etc/nagios/services $ sudo /usr/lib/nagios/plugins/check_rpc -H X.X.X.X -C nfs -c2,3
CRITICAL: RPC program nfs version 2 version 3 udp is not running
Re: showmount: Program not registered
Posted: Fri Sep 28, 2018 12:55 pm
by lmiltchev
Your command is defined as "check-nfs":
define command{
command_name check-nfs
command_line $USER1$/check_rpc -H $HOSTADDRESS$ -C nfs -c2,3
}
but your service uses a command called "check_nfs"...
define service{
use generic-24x7-email
hostgroup_name linux-web-servers
servicegroups data-services
service_description NFS
check_command check_nfs
normal_check_interval 360
}
Re: showmount: Program not registered
Posted: Mon Oct 01, 2018 9:16 am
by shamrozkadiwal
Sorry
lmiltchev, I overlooked the command.cfg. However, I have found another NFS command as
Code: Select all
define command{
command_name check_nfs
command_line $USER1$/check_nfs.pl -H $HOSTADDRESS$
}
and when I tried to run this command from the nagios server to the host, I got this
shkadi@nagios /etc/nagios/commands $ sudo /usr/lib/nagios/plugins/check_nfs.pl -H X.X.X.X
showmount: RPC: Program not registered
Re: showmount: Program not registered
Posted: Tue Oct 02, 2018 10:17 am
by scottwilkerson
Where did you get this plugin? Does it have any instructions on dependencies?
Re: showmount: Program not registered
Posted: Tue Oct 02, 2018 3:07 pm
by shamrozkadiwal
I got the script from the internet very long time ago. However, script works fine with other hosts.