2.2. 选择 authselect 配置集
作为系统管理员,您可以为特定主机选择 authselect
工具的配置集。该配置集将应用于登录到主机的每个用户。
先决条件
-
运行
authselect
命令需要root
凭证
步骤
选择适合您的身份验证供应商的
authselect
配置集。例如,若要登录到使用 LDAP 的公司网络,请选择sssd
。authselect select sssd
# authselect select sssd
Copy to Clipboard Copied! Toggle word wrap Toggle overflow 可选:您可以通过在
authselect select sssd
或authselect select winbind
命令中添加以下选项来修改默认的配置文件设置,例如:-
with-faillock
-
with-smartcard
-
with-fingerprint
-
要查看可用选项的完整列表,请参阅 将脚本从 authconfig 转换为 authselect 或您系统上的
authselect-migration (7)
手册页。
注意
在完成 authselect select
过程前,请确定正确配置了与您的配置集相关的配置文件。例如,如果 sssd
守护进程没有正确配置并处于活动状态,则运行 authselect select
会导致只有本地用户可以使用 pam_unix
进行身份验证。
验证
验证
/etc/nsswitch.conf
中是否存在 SSSD 的sss
条目:Copy to Clipboard Copied! Toggle word wrap Toggle overflow 在
pam_sss.so
条目中查看/etc/pam.d/system-auth
文件的内容:Copy to Clipboard Copied! Toggle word wrap Toggle overflow