Rocky_Linux_8
Sponsored Link

FreeIPA : Replication Setting2021/08/04

 
Configure FreeIPA Replication.
This example is based on the environment like follows.
+----------------------+          |          +----------------------+
| [  FreeIPA Master ]  |10.0.0.40 | 10.0.0.61| [  FreeIPA Replica ] |
|  dlp.ipa.srv.world   +----------+----------+ node01.ipa.srv.world |
|                      |                     |                      |
+----------------------+                     +----------------------+

[1]
[2] On FreeIPA Master Host, Add a replication Host to [ipaservers] group.
Furthermore, it needs to resolve Address Resolution on Master Host and Replica Host.
If you are using FreeIPA integrated DNS but not set reverse zone, Configure like follows.
[root@dlp ~]#
ipa hostgroup-add-member ipaservers --hosts node01.ipa.srv.world

  Host-group: ipaservers
  Description: IPA server hosts
  Member hosts: dlp.ipa.srv.world, node01.ipa.srv.world
-------------------------
Number of members added 1
-------------------------

# if not set reverse zone yet on integrated DNS, set it

# example below is for [10.0.0.0/24] network

[root@dlp ~]#
ipa dnszone-add 0.0.10.in-addr.arpa
# add PTR record in reverse zone

[root@dlp ~]#
ipa dnsrecord-add 0.0.10.in-addr.arpa 40 --ptr-rec dlp.ipa.srv.world.

[root@dlp ~]#
ipa dnsrecord-add 0.0.10.in-addr.arpa 61 --ptr-rec node01.ipa.srv.world.
# if firewalld is running, allow services

[root@dlp ~]#
firewall-cmd --add-service=freeipa-replication

success
[root@dlp ~]#
firewall-cmd --runtime-to-permanent

success
[3] Configure on Replication Server Host.
# if firewalld is running, allow services

[root@node01 ~]#
firewall-cmd --add-service={freeipa-ldap,freeipa-ldaps,dns,ntp,freeipa-replication}

success
[root@node01 ~]#
firewall-cmd --runtime-to-permanent

success
[root@node01 ~]#
dnf module -y install idm:DL1/dns
# setup replication

# if set DNS forwarder, specify [--forwarder=xxx.xxx.xxx.xxx]

[root@node01 ~]#
ipa-replica-install --setup-ca --setup-dns --no-forwarders

Run connection check to master
Connection check OK
Disabled p11-kit-proxy
Configuring directory server (dirsrv). Estimated time: 30 seconds
  [1/38]: creating directory server instance
  [2/38]: tune ldbm plugin
  [3/38]: adding default schema
  
.....
.....

  [6/7]: creating replica keys
  [7/7]: configuring ipa-dnskeysyncd to start on boot
Done configuring DNS key synchronization service (ipa-dnskeysyncd).
Restarting ipa-dnskeysyncd
Restarting named
Updating DNS system records

Global DNS configuration in LDAP server is empty
You can use 'dnsconfig-mod' command to set global DNS options that
would override settings in local named.conf files

The ipa-replica-install command was successful
[4] After finishing to setup replication normally, it's possbile to find existing user accounts or add new accounts on Replication Host.
[root@node01 ~]#
kinit admin

Password for admin@IPA.SRV.WORLD:
[root@node01 ~]#
ipa user-find

---------------
4 users matched
---------------
  User login: admin
  Last name: Administrator
  Home directory: /home/admin
  Login shell: /bin/bash
  Principal alias: admin@IPA.SRV.WORLD, root@IPA.SRV.WORLD
  UID: 1899200000
  GID: 1899200000
  Account disabled: False

  User login: redhat
  First name: redhat
  Last name: redhat
  Home directory: /home/redhat
  Login shell: /bin/sh
  Principal name: redhat@IPA.SRV.WORLD
  Principal alias: redhat@IPA.SRV.WORLD
  Email address: redhat@ipa.srv.world
  UID: 1899200003
  GID: 1899200003
  Account disabled: False
.....
.....
Matched Content