วันพฤหัสบดีที่ 29 เมษายน พ.ศ. 2553

Object class violation when creating group in LDAP using WebSphere Portal

 

Technote (troubleshooting)

Problem(Abstract)

When attempting to create a group using IBM® WebSphere® Portal, you receive an "EJPSG0015E: Data Backend Problem" error. The details show that this is caused by the LDAP server returning an error code 65 (object class violation).

Symptom

SystemOut.log will contain:

... WSMM Message  E com.ibm.ws.wmm.ldap.LdapRepositoryImpl void create(String DN, Attributes attributes) The following Naming Exception occured during processing: "javax.naming.directory.SchemaViolationException: [LDAP: error code 65 - Object Class Violation]; remaining name 'cn=testgroupname,o=ibm'; resolved object com.sun.jndi.ldap.LdapCtx@28da7087".
... CreateGroupCo E com.ibm.wps.command.puma.CreateGroupCommand AbstractCommand.throwCommandFailedException EJPEB0003E: CreateGroupCommand.execute: An exception occurred.
com.ibm.wps.util.DataBackendException: EJPSG0015E: Data Backend Problem
...
Caused by: com.ibm.websphere.wmm.exception.WMMSystemException: The following Naming Exception occured during processing: "javax.naming.directory.SchemaViolationException: [LDAP: error code 65 - Object Class Violation]; remaining name 'cn=testgroupname,o=ibm'; resolved object com.sun.jndi.ldap.LdapCtx@28da7087". at com.ibm.ws.wmm.ldap.LdapRepositoryImpl.create(LdapRepositoryImpl.java:107)

Resolving the problem

Refer to the 'LDAP: error code ...' technote in the related information below which explains that the LDAP server generates the error code 65. Consult with your LDAP administrator to troubleshoot the failure from an LDAP perspective.
You may have to update the WebSphere Member Manager (WMM) configuration to resolve the problem. For example, this error can occur when attempting to create a group in IBM Tivoli Directory Server (ITDS) using the objectClass accessGroup. Consider the case where wmm.xml contains:

<supportedLdapEntryType name="Group" rdnAttrTypes="cn"               objectClassesForRead="accessGroup" objectClassesForWrite="accessGroup" searchBases="o=ibm"/>  

and wmmLDAPServerAttributes.xml contains:

<attributeMap wmmAttributeName="groupMember" pluginAttributeName="uniqueMember" applicableMemberTypes="Group" dataType="String" valueLength="1024" multiValued="true" defaultValue="uid=dummy"/>
If you enable the traces recommended in the WebSphere Member Manager MustGather and attempt to create a group in WebSphere Portal, you will see the following in trace.log:
.WMM Trace Log > com.ibm.ws.wmm.ldap.LdapConnectionImpl DirContext createSubcontext(Name name,  Attributes attrs) Entry cn=testgroupname,o=ibm {objectclass=objectClass: accessgroup, uniquemember=uniquemember: uid=dummy, cn=cn: testgroupname}
...                                                                     
WSMM Message  E com.ibm.ws.wmm.ldap.LdapRepositoryImpl void create(String DN, Attributes attributes) The following Naming Exception occured during processing: "javax.naming.directory.SchemaViolationException: [LDAP: error code 65 - Object Class Violation]; remaining name 'cn=testgroupname,o=ibm'; resolved object com.sun.jndi.ldap.LdapCtx@1faad592"

This failure occurs because the definition of the accessGroup object class does not include uid and uniquemember attributes:

accessgroup :
{                                                                      
1.3.18.0.2.6.75                                                      
NAME 'accessGroup'                                                    
DESC 'A group that is used for access control.'
SUP top STRUCTURAL
MUST cn
MAY (businessCategory $ description $ member $ o $ ou $ owner $ seeAlso)
}                                                                      
Therefore, to correct the problem you have two options. If your LDAP server is configured such that a defaultValue is required for member (see "Mapping LDAP Attributes" link below), then you must update wmmLDAPServerAttributes.xml replacing the entry for wmmAttributeName="groupMember" with (changing pluginAttributeName and defaultValue):

<attributeMap wmmAttributeName="groupMember" pluginAttributeName="member" applicableMemberTypes="Group" dataType="String" valueLength="1024" multiValued="true" defaultValue="cn=dummy"/>
If your LDAP server does not require a defaultValue, you could use the following instead:

<attributeMap wmmAttributeName="groupMember" pluginAttributeName="member" applicableMemberTypes="Group" dataType="String" valueLength="1024" multiValued="true"/>
Use the check-out/check-in procedure to update the WMM configuration if running in a cluster. Restart WebSphere Portal to read the updated WMM configuration.

Related information

'LDAP: error code ...' messages
WMM MustGather
Mapping LDAP Attributes

32 ความคิดเห็น:

  1. 您的部落格文章真棒!!有空我一定會常來逛!! ........................................

    ตอบลบ
  2. 婚姻對男人來說是賭他的自由,對女人而言卻是賭她的幸福。..................................................

    ตอบลบ
  3. 在莫非定律中有項笨蛋定律:「一個組織中的笨蛋,恆大於等於三分之二。」....................................................................

    ตอบลบ
  4. 偶爾上來逛逛,下次不知是否還有緣再進來,先祝您平安順利!!!............................................................

    ตอบลบ
  5. 死亡是悲哀的,但活得不快樂更悲哀。. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

    ตอบลบ
  6. 噴泉的高度,不會超過它的源頭。一個人的事業也是如此,它的成就絕不會超過自己的信念。............................................................

    ตอบลบ
  7. 在你一無所有的時候 是誰在陪伴你 他便是你最重要的人............................................................

    ตอบลบ
  8. 安安唷~~幸運的日子送給妳(你)滿滿的幸福,也祝福你天天都開心唷............................................................

    ตอบลบ
  9. 人生有些波折,才能有些成長,所以不論順逆,凡是成長、成功的助緣,都應該心存感激。.................................................

    ตอบลบ
  10. 好文章就值得回響,如果可以常常看到您的更新,應該是件很幸福的事情~~...............................................................

    ตอบลบ