2.6. 安装 RHEL 8 副本
列出 RHEL 7 环境中存在哪些服务器角色:
[root@rhel7 ~]# ipa server-role-find --status enabled --server rhel7.example.com ---------------------- 3 server roles matched ---------------------- Server name: rhel7.example.com Role name: CA server Role status: enabled Server name: rhel7.example.com Role name: DNS server Role status: enabled Server name: rhel7.example.com Role name: NTP server Role status: enabled [... output truncated ...]可选:如果要在
rhel7.example.com正在使用的rhel8.example.com中使用相同的每服务器转发器,请查看rhel7.example.com的每服务器转发器:[root@rhel7 ~]# ipa dnsserver-show rhel7.example.com ----------------------------- 1 DNS server matched ----------------------------- Server name: rhel7.example.com SOA mname: rhel7.example.com. Forwarders: 192.0.2.20 Forward policy: only -------------------------------------------------- Number of entries returned 1 --------------------------------------------------在
rhel8.example.com上安装 IdM 服务器,来作为 IdM RHEL 7 服务器的副本,包括rhel7.example.com上存在的所有服务器角色,但 NTP 服务器角色除外。要安装上例中的角色,请使用ipa-replica-install命令的这些选项:-
--setup-ca用来设置证书系统组件 --setup-dns和--forwarder来配置集成 DNS 服务器,并设置每服务器转发器来处理 IdM 域外的 DNS 查询注意另外,如果您的 IdM 部署与 Active Directory(AD)属于信任关系,请将
--setup-adtrust选项添加到ipa-replica-install命令中,以便在rhel8.example.com上配置 AD 信任功能。要设置一个 IdM 服务器,其 IP 地址为 192.0.2.1,使用 IP 地址为 192.0.2.20 的每服务器转发器:
[root@rhel8 ~]# ipa-replica-install --setup-ca --ip-address 192.0.2.1 --setup-dns --forwarder 192.0.2.20您不需要指定 RHEL 7 IdM 服务器本身,因为如果 DNS 工作正常,
rhel8.example.com将使用 DNS 自动发现来找到它。
-
-
可选:将外部
NTP时间服务器的_ntp._udp服务(SRV)记录添加到新安装的 IdM 服务器的 DNS 中,即 rhel8.example.com。建议这样做,因为 RHEL 8 中的 IdM 不提供它自己的时间服务。IdM DNS 中时间服务器的 SRV 记录可确保将来的 RHEL 8 副本和客户端安装被自动配置为与 rhel8.example.com 使用的时间服务器同步。这是因为ipa-client-install会查找_ntp._udpDNS 条目,除非在安装命令行界面(CLI)上提供了--ntp-server或--ntp-pool选项。
验证
验证 IdM 服务是否在
rhel8.example.com上运行:[root@rhel8 ~]# ipactl status Directory Service: RUNNING [... output truncated ...] ipa: INFO: The ipactl command was successful在
rhel8.example.com上运行 IdM Healthcheck 以验证服务、复制和证书健康状况:[root@rhel8 ~]# ipa-healthcheck如果 Healthcheck 报告警告或错误,请在弃用任何 RHEL 7 服务器前调查并解决它们。对于目标复制测试,您可以运行:
[root@rhel8 ~]# ipa-healthcheck --source=ipahealthcheck.ds.replication --source=ipahealthcheck.ipa.topology验证
rhel8.example.com的服务器角色与rhel7.example.com的服务器角色相同,但 NTP 服务器角色除外:[root@rhel8 ~]$ kinit admin [root@rhel8 ~]$ ipa server-role-find --status enabled --server rhel8.example.com ---------------------- 2 server roles matched ---------------------- Server name: rhel8.example.com Role name: CA server Role status: enabled Server name: rhel8.example.com Role name: DNS server Role status: enabled可选:显示
rhel7.example.com和rhel8.example.com之间的复制协议详情:[root@rhel8 ~]# ipa-csreplica-manage list --verbose rhel8.example.com Directory Manager password: rhel7.example.com last init status: None last init ended: 1970-01-01 00:00:00+00:00 last update status: Error (0) Replica acquired successfully: Incremental update succeeded last update ended: 2019-02-13 13:55:13+00:00可选:如果您的 IdM 部署与 AD 有信任关系,请验证它是否正常工作:
- 链接:验证 Kerberos 配置
尝试解析
rhel8.example.com上的 AD 用户:[root@rhel8 ~]# id aduser@ad.domain
验证
rhel8.example.com是否与NTP服务器同步:[root@rhel8 ~]# chronyc tracking Reference ID : CB00710F (ntp.example.com) Stratum : 3 Ref time (UTC) : Tue Nov 16 09:49:17 2021 [... output truncated ...]