Custom Schema Best Practices293.4.8. Custom Schema Best PracticesWhen using schema files, be sure to create schema which will be compatible and easy to manage.3.4.8.1. Naming Schema FilesWhen naming custom schema files, use the following naming format:[00-99]yourName.ldifName custom schema files lower (numerically and alphabetically) than 99user.ldif. This letsDirectory Server write to 99user.ldif, both through LDAP tools and the Directory Server Console.The 99user.ldif file contains attributes with an X-ORIGIN value of 'user defined'; however,the Directory Server writes all 'user defined' schema elements to the highest named file,numerically then alphabetically. If there is a schema file called 99zzz.ldif, the next time the schemais updated (either through LDAP command-line tools or the Directory Server Console) all of theattributes with an X-ORIGIN value of 'user defined' are written to 99zzz.ldif. The result is twoLDIF files that contain duplicate information, and some information in the 99zzz.ldif file might beerased.3.4.8.2. Using 'user defined' as the OriginDo not use 'user defined' in the X-ORIGIN field of custom schema files (such as60example.ldif), because 'user defined' is used internally by the Directory Server whena schema is added over LDAP. In custom schema files, use something more descriptive, such as'Example Corp. defined'.However, if the custom schema elements are added directly to the 99user.ldif manually, use'user defined' as the value of X-ORIGIN. If a different X-ORIGIN value is set, the server simplymay overwrite it.Using an X-ORIGIN of value 'user defined' ensures that schema definitions in the99user.ldif file are not removed from the file by the Directory Server. The Directory Serverdoes not remove them because it relies on an X-ORIGIN of value 'user defined' to tell it whatelements should reside in the 99user.ldif file.For example:attributetypes: ( exampleContact-oid NAME 'exampleContact'DESC 'Example Corporate contact'SYNTAX 1.3.6.1.4.1.1466.115.121.1.15X-ORIGIN 'Example defined')After the Directory Server loads the schema entry, it appears as follows:attributetypes: ( exampleContact-oid NAME 'exampleContact'DESC 'Example Corporate contact'SYNTAX 1.3.6.1.4.1.1466.115.121.1.15X-ORIGIN ('Example defined' 'user defined') )