This post covers overview of Schema, Object Class and Attributesin OID. Schema Extension (creating object class, adding attribute) is NOT a regular task for OID administrators but one should know basics and tool/steps to modify/extend OID Schema.
Schema : contains rules about kinds of objects you can store in OID. As shown in figure above schema definition is stored in cn=subSchemaSubentry under Root DSE . Use ldapadd or ODSMto add subSchemaSubentry entry (You cannot use bulkload to add subSchemaSubentry).
Attribute : is item/property attached to an entity/entry in OID. firstname, lastname, address are example of attributes for entity/entry user. Attribute can be Application Attributes(example firstname, lastname, photo) or System Configuration Attribute(example createTimestamp, createdBy, modifiedBy). Attribute can hold single value or multiple value.
Object Class : group of attribute that define structure of entry/entity is called Object Class (for example user, person, OrganizationalPerson are Object Class). ObjectClass contains mandatory and optional attribute (For example for object class Person, cn & sn attribute are mandatory attribute where as addressis optional attribute). You assign objectClass to an entity/entry. There are three type of Object Class
a) Structural : Structural object classes describe the basic aspects of an object. example, people, person, printer ..
b) Auxiliary : Auxiliary object classes are groupings of optional attributes that expand the existing list of attributes in an entry. Unlike structural object classes, they do not place restrictions on where an entry may be stored, and you can attach them to any entry regardless of that entry’s location in the DIT.
c) Abstract : An abstract object class is a virtual object class. It is used only for convenience when specifying the highest levels of the object class hierarchy. It cannot be the only object class for an entry. For example, the object class topis an abstract object class. It is required as a superclass for all structural object classes, but it cannot be used alone.
How to Add/Modify/Delete Object Class ?
You can use a) Oracle Directory Services Manager (More on ODSM here) or b) command line tool (ldapXXXX) to add/modify/delete Object Class.
To Manage/Create Object Class using ODSM: Login to ODSM (http://host:7005/odsm) -> Schema -> Object Classes -> Add/Modify
To add/modify/delete Object Class using Command Line: Use ldap commands like ldapsearch, ldapmodify .
Things good to know about managing OID Schema
1. Every structural object class must have topas a superclass (top is name of object class)
2. The name and the object identifier of an object class must be unique across all the schema components (Object Identifier is string of decimal numbers, which uniquely identifies an Object)
3. The Object Identifier must begin with the unique identifier 2.16.840.1.113894 followed by either the Oracle-supplied prefix.9999 or a site-specific prefix.
4. It is possible to redefine mandatory attributesin a superclass into optional attributes in the new object class. Conversely, optional attributesin a superclass can be redefined into mandatory attributes in the new object class.
5. You cannot modify an object class that is part of the standard LDAP schema. You can, however, modify user-defined object classes.
6. If existing object classes do not have the attributes you need, you can create an auxiliary object class and associate the needed attributes with that object class.
7. You cannot add additional mandatory attributes to an existing object class (Use auxiliary class to include existing objectclass as superclass and add additional attributes in auxiliary class).
8. You cannotremove attributes or super-classes from an existing object class.
9. You cannot convert structural object classes to other object class types (like structural or abstract).
10. You should not modify an object class if there are entries already associated with it.
11. You cannot delete object classes from the base schema.
12. You can delete object classes that are not in the base schema if they are not directly or indirectly referenced by other schema components.
Related Posts for OID
- Oracle Internet Directory OID
- Oracle Internet Directory – Basics II
- OID to OID/Active Directory/iPlanet other LDAP Server Integration
- Multi Master OID Replication
- OID Architecture
- Oracle Internet Directory , OID Troubleshooting
- Server Chaining in OID
- OID Quesries/ Scripts FAQ
- OIDADMIN Client
- Oracle Identity Management (OID) 11g installation Issues on Linux
- OID 11g – Oracle Directory Services Manager (ODSM)
- DIP : Synchronization, Provisioing, Connectors, DSS in Oracle Directory Services (ODS) 11g
- OID Replication – Suppliers, Consumers, DRG, ASR/LDAP based replication
- ASR setup has failed – Error occurred while dropping database link : ORA-02084 : database name is missing a component while Configuring Multi Master OID replication using “remtool -asrsetup”
- OID 11g Down : Unable to Start OID 11g using OPMN (ODS schema locked ORA-28002)
- OID/Directory Services 11g – Schema, Object Class, Attributes
- OID 11g Distributed Install : DIP/ODSM (Java Component) & OID (LDAP/REPLD) on different machine
- OID Server Mode R, RW, RM: LDAP: error code 53 – Server currently in read only mode
- How to change OID 11g database schema (ODS) password
- How to add custom attribute, Object Classe in OID from command line or GUI
- Oracle Internet Directory (OID) and Real Application Cluster (RAC) database : Things you must know
- How to Update User Password in OID (single account or bulk) – command line or GUI
- Error starting OID 11g during configuration stage of OID installation on Windows Server “ProvisionException: Failed to start the component”
- How to delete Entries in OID 11g in Bulk – Delete Failed : Ldap Error Code 66 Not allowed on Non-Leaf
- How to find latest changelog number (or changes) in OID ?
- Context Initialization Error on running ldapsearch commands on OID Server
- How to find OID version and patches applied on OID Home ?
- How to change OID 11g LDAP/LDAPS listen port
- How to find/audit Failed Login Attempts in OID 11g
- Step by Step configuration of OID Multi Master Replication – LDAP based in OID 11g
- OID 11g LDAP based Multi Master replication : Configuration Entries you must know
- Configure SSL for Oracle Internet Directory (OID)
- How to backup Oracle Internet Directory (OID) 11g – Data : Full / Partial