DB2 Version 9.7 for Linux, UNIX, and Windows

db2schex - Active Directory schema extension command

Extends the Microsoft Active Directory schema to include the DB2® object classes and attribute definitions that you require to use the Lightweight Directory Access Protocol (LDAP) directory server feature with Windows Server 2003 and later.

You should run this command before installing DB2 products and creating databases otherwise you have to manually register the node and catalog the databases. For more information, see the "Extending the Active Directory Schema for LDAP directory services (Windows)" topic.

The db2schex command is included on the product DVD. The location of this command on the DVD is in the path x:\db2\windows\utilities, where x: specifies the DVD drive.

Authorization

To update the Active Directory schema, you must be a member of the Schema Administrators group or have been delegated the rights to update the schema.

Required connection

Access to a Windows Domain Controller server in the target domain.

Command syntax

Read syntax diagramSkip visual syntax diagram
>>-db2schex--+----------------------------+--+-----+--+-----+--->
             '- -b--bindDN-- -w--password-'  '- -k-'  '- -u-'   

>--+---------------+-------------------------------------------><
   '- -x--filename-'   

Command parameters

-b bindDN
Specifies the user Distinguished Name.
-w password
Specifies the bind password.
-k
Forces the uninstall to continue, ignoring errors.
-u
Uninstall the schema.
-x filename
Specify this parameter to write the changes to the Active Directory schema, performed by the utility, to a file.

Examples

To install the DB2 schema, execute the following command:
db2schex
To install the DB2 schema and specify a bind DN and password, execute the following command:
db2schex -b "cn=A_Name,dc=toronto1,dc=ibm,dc=com" -w password 
or,
db2schex -b Administrator -w password 
To uninstall the DB2 schema, execute the following command:
db2schex -u
To uninstall the DB2 schema and ignore errors, execute the following command:
db2schex -u -k

Usage notes

If bindDN and password are not specified, db2schex binds as the currently logged in user.

The bindDN parameter can be specified as a Windows username.

The DB2 schema extension command carries out the following tasks:
  • Detects which server is the Schema Master
  • Binds to the Domain Controller that is the Schema Master
  • Ensures that the user has sufficient rights to add classes and attributes to the schema
  • Ensures that the Schema Master is writable (that is, the safety interlock in the registry is removed)
  • Creates all the new attributes
  • Creates all the new object classes
  • Detects errors and, if they occur, the program will roll back any changes to the schema.