使用LDAP认证
网络用户:由网络中一台服务器提供用户名、密码
本地用户:/etc/passwd
准备两台 虚拟机
什么是LDAP?
轻量级目录访问协议
– Lightweight Directory Access Protocol
– 提供的信息包括:用户名、密码、通信录、主机名映
射记录、......
LDAP服务器:classroom.example.com (虚拟机上自行创建)
客户端:虚拟机Server
1.安装sssd客户端软件,与服务端LDAP服务器沟通
[root@server0 ~]# yum -y install sssd
2.安装图形工具配置sssd软件
[root@server0 ~]# yum -y install authconfig-gtk
3.运行authconfig-gtk图形工具,配置sssd软件
[root@server0 ~]# exit
登出
[root@room9pc01 ~]# ssh -X root@172.25.0.11
[root@server0 /]# authconfig-gtk
选择LDAP
dc=example,dc=com #指定服务端域名
classroom.example.com #指定服务端主机名
勾选TLS加密
使用证书加密: http://classroom.example.com/pub/example-ca.crt
选择LDAP密码
4.验证
[root@server0 ~]# systemctl restart sssd
[root@server0 ~]# grep ldapuser0 /etc/passwd
[root@server0 ~]# id ldapuser0