showmount: Program not registered

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
shamrozkadiwal
Posts: 74
Joined: Thu Jan 25, 2018 1:13 am

showmount: Program not registered

Post 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.
Attachments
awhu013a.png
User avatar
mcapra
Posts: 3739
Joined: Thu May 05, 2016 3:54 pm

Re: showmount: Program not registered

Post 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.
Former Nagios employee
https://www.mcapra.com/
User avatar
lmiltchev
Former Nagios Staff
Posts: 13587
Joined: Mon May 23, 2011 12:15 pm

Re: showmount: Program not registered

Post by lmiltchev »

Any updates @shamrozkadiwal?
Be sure to check out our Knowledgebase for helpful articles and solutions!
shamrozkadiwal
Posts: 74
Joined: Thu Jan 25, 2018 1:13 am

Re: showmount: Program not registered

Post 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.
User avatar
lmiltchev
Former Nagios Staff
Posts: 13587
Joined: Mon May 23, 2011 12:15 pm

Re: showmount: Program not registered

Post by lmiltchev »

Whenever you are ready.
Be sure to check out our Knowledgebase for helpful articles and solutions!
shamrozkadiwal
Posts: 74
Joined: Thu Jan 25, 2018 1:13 am

Re: showmount: Program not registered

Post 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
User avatar
lmiltchev
Former Nagios Staff
Posts: 13587
Joined: Mon May 23, 2011 12:15 pm

Re: showmount: Program not registered

Post 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
}
Be sure to check out our Knowledgebase for helpful articles and solutions!
shamrozkadiwal
Posts: 74
Joined: Thu Jan 25, 2018 1:13 am

Re: showmount: Program not registered

Post 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
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: showmount: Program not registered

Post by scottwilkerson »

Where did you get this plugin? Does it have any instructions on dependencies?
Former Nagios employee
Creator:
ahumandesign.com
enneagrams.com
shamrozkadiwal
Posts: 74
Joined: Thu Jan 25, 2018 1:13 am

Re: showmount: Program not registered

Post by shamrozkadiwal »

I got the script from the internet very long time ago. However, script works fine with other hosts.
Locked