您的位置:首页 > 运维架构 > Linux

Linux下NIS客户端机器不能使用普通用户(非root用户)登录!

2011-12-16 21:10 2206 查看
现象:

Linux机器上不能使用普通用户登录,登录时等待时间很长,不能登录,

手动挂载NIS服务端的/home目录时,出现如下错误:

do_ypcall: clnt_call: RPC: Unable to send; errno = Network is unreachable do_ypcall

检查发现该台机器是NIS客户机器。

解决:

启动NIS服务器的相关服务。

/etc/init.d/portmap start

/etc/init.d/ypserv start

/etc/init.d/yppasswdd start

启动NIS客户端的相关服务。

/etc/init.d/ypbind start

发现启动Failed!

检查NIS服务器的配置文件 /etc/ypserv.conf

# The following, when uncommented, will give you shadow like passwords.

# Note that it will not work if you have slave NIS servers in your

# network that do not run the same server as you.

# Host : Domain : Map : Security

#

# * : * : passwd.byname : port

# * : * : passwd.byuid : port

127.0.0.0/255.0.0.0 : * : * : none

10.10.104.0/255.255.255.0 : * : * : none

192.168.0.0/255.255.255.0 : * : * : none

* : * : * : deny

然后查看客户机器的IP地址,发现不在以下网段内:

10.10.104.0/255.255.255.0

192.168.0.0/255.255.255.0

检查发现客户机器网卡eth1没启动,该网卡的IP地址在网段 192.168.0.0/255.255.255.0 内。

于是启动网卡eth1,然后再启动客户端的NIS相关服务。

[root@gd87 ~]# /etc/init.d/ypbind start

Binding to the NIS domain:

Listening for an NIS domain server.


然后客户机器便可以使用普通用户登录。
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: