Keep structure of groups migrated with ipa migrate-ds
ipa migrate-ds
I have a LDAP server with groups and subgroups. When I migrate them to FreeIPA with ipa migrate-ds --group-container=.... --scope=subtree all groups and subgroups are migrated but flatten in a unique level in cn=groups,cn=accounts,dc=DOMAIN
ipa migrate-ds --group-container=.... --scope=subtree
cn=groups,cn=accounts,dc=DOMAIN
For example, I have ou=role,dc=DOMAIN as group with leaf cn=role1,ou=role,dc=DOMAIN entry I also have ou=subrole,ou=role,dc=DOMAIN as subgroup with leafs cn=subrole1,ou=subrole,ou=role,dc=DOMAIN entries
ou=role,dc=DOMAIN
cn=role1,ou=role,dc=DOMAIN
ou=subrole,ou=role,dc=DOMAIN
cn=subrole1,ou=subrole,ou=role,dc=DOMAIN
This means I cannot have subgroups with same name
ipa migrate-ds ldap://LDAP --bind-dn=BIND --group-container=ou=role --scope=subtree
Groups and subgroups are flatten in cn=groups,cn=accounts : cn=role1,cn=groups, cn=subrole1,cn=groups
cn=groups,cn=accounts
cn=role1,cn=groups, cn=subrole1,cn=groups
Keep incoming structure in cn=groups
cn=groups
FreeIPA 4.12.2
My LDAP server source is OpenLDAP 2.5.13
This is by design. FreeIPA does not have support for OUs and we do not plan adding any.
This was one of the original design decisions for FreeIPA: all objects have a flat storage structure under its own subtree. This applies to every single object type.
For example:
$ ipa env|grep container_|egrep '_user|_group|_host' container_group: cn=groups,cn=accounts container_host: cn=computers,cn=accounts container_hostgroup: cn=hostgroups,cn=accounts container_user: cn=users,cn=accounts
Metadata Update from @abbra: - Issue close_status updated to: invalid - Issue status updated to: Closed (was: Open)