Resolution
Directory and Resource Administrator 7.x
symptom
Error: 'Error saving the changes to the User. A constraint violation occurred.' when running a script to create a Microsoft Exchange 2000 Mailbox.
symptom
Running a script to create an Exchange 2000 mailbox returns:
User.Put "mailNickname", name
User.Put "homeMDB", MDB
User.SetInfoCreateMailBox.VBS(171, 3) NetIQ DRA: Error saving the changes to the User.
A constraint violation occurred.
cause
The In.MailboxStore path did not contain a DCbind value.
fix
If using the Varset to create the mailbox, the In.MailboxStore path must contain a DCbind in the string.
For example, the Varset from a MailboxCreate from the GUI would look like this:
[In.MailboxStore]<VT_BSTR> LDAP://DCName/CN=M002SG1DB1,CN=M002SG1,CN=InformationStore,CN=TKCMGEXM002,CN=Servers,CN=Tokyo,CN=Administrative Groups,CN=ACME,CN=Microsoft Exchange,CN=Services,CN=Configuration,DC=ACME,DC=Com
The varset from the script would have a path like below:
[In.MailboxStore]
LDAP://CN=M002SG1DB1,CN=M002SG1,CN=InformationStore,CN=TKCMGEXM002,CN=Servers,CN=Tokyo,CN=Administrative Groups,CN=ACME,CN=Microsoft Exchange,CN=Services,CN=Configuration,DC=ACME,DC=Com
To troubleshoot this issue, enable the dump Varset trigger or examine the Server logs and compare the Varset information. To resolve this issue, hard code a DCvalue so the In.MailboxStore has the correct syntax.