码迷,mamicode.com
首页 > 其他好文 > 详细

NIS实现用户登录+家目录服务器共享

时间:2018-05-10 15:35:05      阅读:140      评论:0      收藏:0      [点我收藏+]

标签:linux   杂谈   

本次的服务端是Proxy 客户端是Client

[root@proxy ~]# yum -y install ypserv ypbind
[root@proxy ~]# vim /etc/sysconfig/network
NISDOMAIN=hpc
[root@proxy ~]# systemctl restart ypserv
[root@proxy ~]# systemctl restart yppasswdd
[root@proxy ~]# cd /var/yp /
[root@proxy yp]# make


[root@proxy ~]# vim /etc/yp.conf
domain hpc server 192.168.4.5 ###### 服务端地址
[root@proxy ~]# vim /etc/nsswitch.conf +33 ##### 直接到配置文件的第33行
passwd: files nis sss
shadow: files nis sss
group: files nis sss
[root@proxy ~]# systemctl restart ypbind

[root@proxy~]scp /etc/yp.conf /etc/nsswitch.conf 192.168.4.100:/etc/sysconfig/
[root@client ~]# yum -y install ypbind.x86_64
[root@client ~]# systemctl restart ypbind
[root@client ~]# ypcat passwd #####看服务端的用户
[root@client ~]# ssh test@192.168.4.5 ###测试

NIS实现用户登录+家目录服务器共享

标签:linux   杂谈   

原文地址:http://blog.51cto.com/13740508/2114839

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!