NIS Error Message Solution failed to send 'clear' to local ypserv: RPC: Program

While we configure NIS we do the following step
[root@localhost html]# /usr/lib/yp/ypinit -m
At this point, we have to construct a list of the hosts which will run NIS
servers. sys.example.com is in the list of NIS server hosts. Please continue to add
the names for the other hosts, one per line. When you are done with the
list, type a .
next host to add: sys.example.com
next host to add:
The current list of NIS servers looks like this:
sys.example.com
Is this correct? [y/n: y] y
We need a few minutes to build the databases...
Building /var/yp/(none)/ypservers...
Running /var/yp/Makefile...
gmake[1]: Entering directory `/var/yp/(none)'
Updating passwd.byname...
while I configure I got the following error message
failed to send 'clear' to local ypserv: RPC: Program not registeredUpdating passwd.byuid...
failed to send 'clear' to local ypserv: RPC: Program not registeredUpdating group.byname...
failed to send 'clear' to local ypserv: RPC: Program not registeredUpdating group.bygid...
failed to send 'clear' to local ypserv: RPC: Program not registeredUpdating hosts.byname...
failed to send 'clear' to local ypserv: RPC: Program not registeredUpdating hosts.byaddr...
failed to send 'clear' to local ypserv: RPC: Program not registeredUpdating rpc.byname...
failed to send 'clear' to local ypserv: RPC: Program not registeredUpdating rpc.bynumber...
failed to send 'clear' to local ypserv: RPC: Program not registeredUpdating services.byname...
failed to send 'clear' to local ypserv: RPC: Program not registeredUpdating services.byservicename...
failed to send 'clear' to local ypserv: RPC: Program not registeredUpdating netid.byname...
failed to send 'clear' to local ypserv: RPC: Program not registeredUpdating protocols.bynumber...
failed to send 'clear' to local ypserv: RPC: Program not registeredUpdating protocols.byname...
failed to send 'clear' to local ypserv: RPC: Program not registeredUpdating mail.aliases...
failed to send 'clear' to local ypserv: RPC: Program not registeredgmake[1]: Leaving directory `/var/yp/(none)'
sys.example.com has been set up as a NIS master server.
Now you can run ypinit -s sys.example.com on all slave server.
[root@localhost html]# cd /var/yp/
[root@localhost yp]# make
gmake[1]: Entering directory `/var/yp/(none)'
Updating passwd.byname...
failed to send 'clear' to local ypserv: RPC: Program not registeredUpdating passwd.byuid...
failed to send 'clear' to local ypserv: RPC: Program not registeredUpdating group.byname...
failed to send 'clear' to local ypserv: RPC: Program not registeredUpdating group.bygid...
failed to send 'clear' to local ypserv: RPC: Program not registeredUpdating netid.byname...
failed to send 'clear' to local ypserv: RPC: Program not registeredgmake[1]: Leaving directory `/var/yp/(none)'


Solution For that Problem
while we configure NIS
We need to Edit the following file
[script@redhat yp]# vi /var/yp/Makefile
Int the 109 Add # symbol before the hosts
ll: passwd group #hosts rpc services netid protocols mail \
Restart the Following service
portmap and ypserv service Then try it will work perfectly without any issue.


NIS Error Message -2
#/usr/lib64/yp/ypinit -m
failed to send 'clear' to local ypserv: RPC: Unknown hostUpdating passwd.byuid...
failed to send 'clear' to local ypserv: RPC: Unknown hostUpdating group.byname...
failed to send 'clear' to local ypserv: RPC: Unknown hostUpdating group.bygid...
failed to send 'clear' to local ypserv: RPC: Unknown hostUpdating hosts.byname...
failed to send 'clear' to local ypserv: RPC: Unknown hostUpdating hosts.byaddr...
failed to send 'clear' to local ypserv: RPC: Unknown hostUpdating rpc.byname...
failed to send 'clear' to local ypserv: RPC: Unknown hostUpdating rpc.bynumber...
failed to send 'clear' to local ypserv: RPC: Unknown hostUpdating services.byname...
failed to send 'clear' to local ypserv: RPC: Unknown hostUpdating services.byservicename...
failed to send 'clear' to local ypserv: RPC: Unknown hostUpdating netid.byname...
failed to send 'clear' to local ypserv: RPC: Unknown hostUpdating protocols.bynumber...
failed to send 'clear' to local ypserv: RPC: Unknown hostUpdating protocols.byname...
failed to send 'clear' to local ypserv: RPC: Unknown hostUpdating mail.aliases...
failed to send 'clear' to local ypserv: RPC: Unknown hostgmake[1]:


Update the proper localhost.localdoman in /etc/hosts file.
then Update the NIS Database #/usr/lib64/yp/ypinit -m
It will work perfectly.

Related post