I have a NIS client that has moved to a new building with a new network address.
I added the IP to the hosts.allow, opened the firewall, and added it to the securenets, and the yp/hosts file.
The client ypbind is successful, but yp doesn't work. I can't login at all.
Code:
# /etc/init.d/ypbind restart
Shutting down NIS service: [ OK ]
Starting NIS service: [ OK ]
Binding NIS service: [ OK ]
I try to ssh, and I get user does not exists.
On Client:
yptest fails with:
Code:
ypcat passwd
nickname file /var/yp/nicknames does not exist.
No such map passwd. Reason: Internal NIS error
[root@client ~]# su me
su: user me does not exist
[root@client ~]# yptest
Test 1: domainname
Configured domainname is "astr"
Test 2: ypbind
Used NIS server: fqdn.mynisserver.com
Test 3: yp_match
WARNING: No such map in server's domain (Map passwd.byname, key nobody)
Test 4: yp_first
WARNING: No such map in server's domain (Map passwd.byname)
Test 5: yp_next
-- skipped --
Test 6: yp_master
WARNING: No such map in server's domain (Map passwd.byname)
Test 7: yp_order
WARNING: No such map in server's domain (Map passwd.byname)
Test 8: yp_maplist
hosts.byaddr
netid.byname
hosts.byname
rpc.bynumber
ypservers.old
services.byname
passwd.byname.old
passwd.byuid
passwd.byname
services.byservicename
rpc.byname
protocols.byname
group.bygid
shadow.byname
netgroup.byhost
netgroup.byuser
group.byname
protocols.bynumber
netgroup
mail.aliases
ypservers
Test 9: yp_all
WARNING: Internal NIS error (Map passwd.byname)
5 tests failed
yp.conf
Code:
domain astr server fqdn.mynisserver.com
ypserver fqdn.mynisserver.com
nsswitch
Code:
#
# /etc/nsswitch.conf
#
# An example Name Service Switch config file. This file should be
# sorted with the most-used services at the beginning.
#
# The entry '[NOTFOUND=return]' means that the search for an
# entry should stop if the search in the previous entry turned
# up nothing. Note that if the search failed due to some other reason
# (like no NIS server responding) then the search continues with the
# next entry.
#
# Legal entries are:
#
# nisplus or nis+ Use NIS+ (NIS version 3)
# nis or yp Use NIS (NIS version 2), also called YP
# dns Use DNS (Domain Name Service)
# files Use the local files
# [NOTFOUND=return] Stop searching if not found so far
#
passwd: files nis
shadow: files nis
group: files nis
hosts: files nis dns
services: nis [NOTFOUND=return] files
networks: nis [NOTFOUND=return] files
protocols: nis [NOTFOUND=return] files
rpc: nis [NOTFOUND=return] files
ethers: nis [NOTFOUND=return] files
netmasks: nis [NOTFOUND=return] files
bootparams: nis [NOTFOUND=return] files
netgroup: nis
publickey: nis
automount: files nis
aliases: files nis
On Server:
Let's pretend the client IP is 10.10.10.10
hosts.allow:
iptables:
Code:
-A INPUT -s 10.10.10.10 -d 0/0 -j ACCEPT
securenets:
yp/hosts:
Code:
10.10.10.10 fqdn.client.com client-alias
Did I forget something? I'm baffled. I've never had a client bind to the server but not work.