How to:
The UMC modules for domain management enable comprehensive management of a domain’s data. Extended attributes offer the possibility of integrating new attributes into the domain administration that are not covered by the UCS standard scope. Extended attributes are also used by third-party providers for the integration of solutions in UCS.
Hint
An extended attribute can also be created in a non-UCS school environment, I implemented it in this environment by request.
More informations: 4.8. Erweiterung von UMC-Modulen mit erweiterten Attributen — Univention Corporate Server - Handbuch für Benutzer und Administratoren
Step 1: Create new custom attribute
You could create new custom attribute in the following path:
LDAP-Directory/univention/custom attributes
Step 2: Choose the Type
Choose the Type Settings: Extended attribute
Step 3: Add your settings for the attribute
You have to add your settings in the tab General. In my example i create a location attribute.
Step 4: Set the right Module
In my example i will create an attribute to set a value for the location for each OU.
Step 5: Set the LDAP mapping
You have to set the LDAP object class and attribute to univentionFreeAttributes and univentionFreeAttribute
Hint
It is possible to set up to 20 univentionFreeAttributes. Make sure that the selected attribute is not in use, otherwise there will be a conflict in the LDAP.
Step 6: Set the tab layout
In my example i set the tab layout to Location. This creates a new tab with the name, which can then be found under the settings of the respective OU.
Step 7: Set the syntax class
In my example i just want to set an value for the location, so i used the syntax string. I prefer to set the option Editable after creation to make this attribute more customizable.
Save everything and create the attribute with that.
Step 8: Select and edit an OU
Now select an OU in the LDAP directory, highlight it, and right-click to select Edit.
You will now see a new tab with the name Location and can set a value.
This allows you to use your extended attribute on the OU.
udm container/ou list --filter ou=mejneschool2
ou=mejneschool2
DN: ou=mejneschool2,dc=ucs5schoolhejne,dc=intranet
Location: Bremen
computerPath: 0
description: None
dhcpPath: 0
displayName: mejneschool2
dnsPath: 0
domaincontrollerPath: 0
entryUUID: b08fc31a-92a7-103e-9f18-d3f8a75964de
gPLink: None
groupPath: 0
licensePath: 0
mailPath: 0
modifyTimestamp: 20240510152713Z
name: mejneschool2
networkPath: 0
policyPath: 0
printerPath: 0
sharePath: 0
ucsschoolClassShareFileServer: cn=mejneschool2,cn=dc,cn=server,cn=computers,ou=mejneschool2,dc=ucs5schoolhejne,dc=intranet
ucsschoolHomeShareFileServer: cn=mejneschool2,cn=dc,cn=server,cn=computers,ou=mejneschool2,dc=ucs5schoolhejne,dc=intranet
ucsschoolRole: school:school:mejneschool2
userPath: 0
univentionPolicyReference: cn=dhcp-dns-clear,cn=policies,ou=mejneschool2,dc=ucs5schoolhejne,dc=intranet
univentionPolicyReference: cn=ou-default-ucr-policy,cn=policies,ou=mejneschool2,dc=ucs5schoolhejne,dc=intranet
univention-ldapsearch ou=mejneschool2
dn: ou=mejneschool2,dc=ucs5schoolhejne,dc=intranet
ou: mejneschool2
displayName: mejneschool2
ucsschoolRole: school:school:mejneschool2
univentionObjectType: container/ou
ucsschoolHomeShareFileServer: cn=mejneschool2,cn=dc,cn=server,cn=computers,ou=mejneschool2,dc=ucs5schoolhejne,dc=intranet
ucsschoolClassShareFileServer: cn=mejneschool2,cn=dc,cn=server,cn=computers,ou=mejneschool2,dc=ucs5schoolhejne,dc=intranet
univentionPolicyReference: cn=dhcp-dns-clear,cn=policies,ou=mejneschool2,dc=ucs5schoolhejne,dc=intranet
univentionPolicyReference: cn=ou-default-ucr-policy,cn=policies,ou=mejneschool2,dc=ucs5schoolhejne,dc=intranet
univentionFreeAttribute1: Bremen
objectClass: top
objectClass: ucsschoolOrganizationalUnit
objectClass: univentionFreeAttributes
objectClass: univentionPolicyReference
objectClass: organizationalUnit
objectClass: univentionObject
Optional Step 9: Create the extended attribute via udm command
udm settings/extended_attribute create --position "cn=custom attributes,cn=univention,$(ucr get ldap/base)" --set name=Location --set shortDescription=Location --set tabName=Location --set CLIName=Location --set mayChange=1 --set module="container/ou" --set objectClass=univentionFreeAttributes --set ldapMapping=univentionFreeAttribute1 --set syntax=string --set copyable=1 --set deleteObjectClass=1