You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@directory.apache.org by "Aaron J Angel (JIRA)" <ji...@apache.org> on 2011/08/26 17:38:29 UTC

[jira] [Created] (DIRSERVER-1647) Unable to enable/modify/delete schema

Unable to enable/modify/delete schema
-------------------------------------

                 Key: DIRSERVER-1647
                 URL: https://issues.apache.org/jira/browse/DIRSERVER-1647
             Project: Directory ApacheDS
          Issue Type: Bug
          Components: schema
    Affects Versions: 2.0.0-M2
            Reporter: Aaron J Angel


Attempting to edit, enable, or delete a disabled schema fails with the following:

Error while executing LDIF
 - [LDAP: error code 53 - UNWILLING_TO_PERFORM: failed for MessageType : MODIFY_REQUES
  javax.naming.OperationNotSupportedException: [LDAP: error code 53 - UNWILLING_TO_PERFORM: failed for MessageType : MODIFY_REQUEST
Message ID : 22
    Modify Request
        Object : 'cn=nis,ou=schema'
            Modification[0]
                Operation :  replace
                Modification
    m-disabled: FALSE
org.apache.directory.shared.ldap.model.message.ModifyRequestImpl@b9bf625a: ERR_11001 Cannot load the unknown schema nis]; remaining name 'cn=nis,ou=schema'
	at com.sun.jndi.ldap.LdapCtx.mapErrorCode(LdapCtx.java:3105)
	at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2978)
	at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2785)
	at com.sun.jndi.ldap.LdapCtx.c_modifyAttributes(LdapCtx.java:1468)
	at com.sun.jndi.toolkit.ctx.ComponentDirContext.p_modifyAttributes(ComponentDirContext.java:273)
	at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.modifyAttributes(PartialCompositeDirContext.java:190)
	at org.apache.directory.studio.connection.core.io.jndi.JNDIConnectionWrapper$2.run(JNDIConnectionWrapper.java:454)
	at org.apache.directory.studio.connection.core.io.jndi.JNDIConnectionWrapper.runAndMonitor(JNDIConnectionWrapper.java:1272)
	at org.apache.directory.studio.connection.core.io.jndi.JNDIConnectionWrapper.checkConnectionAndRunAndMonitor(JNDIConnectionWrapper.java:1203)
	at org.apache.directory.studio.connection.core.io.jndi.JNDIConnectionWrapper.modifyEntry(JNDIConnectionWrapper.java:502)
	at org.apache.directory.studio.ldapbrowser.core.jobs.ImportLdifJob.importLdifRecord(ImportLdifJob.java:507)
	at org.apache.directory.studio.ldapbrowser.core.jobs.ImportLdifJob.importLdif(ImportLdifJob.java:267)
	at org.apache.directory.studio.ldapbrowser.core.jobs.ExecuteLdifRunnable.run(ExecuteLdifRunnable.java:143)
	at org.apache.directory.studio.ldapbrowser.core.jobs.UpdateEntryRunnable.run(UpdateEntryRunnable.java:58)
	at org.apache.directory.studio.connection.ui.RunnableContextRunner$1.run(RunnableContextRunner.java:113)
	at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:121)

  [LDAP: error code 53 - UNWILLING_TO_PERFORM: failed for MessageType : MODIFY_REQUEST
Message ID : 22
    Modify Request
        Object : 'cn=nis,ou=schema'
            Modification[0]
                Operation :  replace
                Modification
    m-disabled: FALSE
org.apache.directory.shared.ldap.model.message.ModifyRequestImpl@b9bf625a: ERR_11001 Cannot load the unknown schema nis]


Upon installation, the nis schema was enabled by removing the m-disabled attribute from the entry.  Upon discovering that posixGroup was STRUCTURAL, I disabled the nis schema.  Now, when trying to modify the objectClass entry for posixGroup, or even when attempting to delete the nis schema entirely to start over, the above error message is presented in Directory Studio.

For my application, I need to edit or replace the default nis schema with one compatible with rfc2307bis (e.g., posixGroup must be AUXILIARY, not STRUCTURAL).

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (DIRSERVER-1647) Unable to enable/modify/delete schema

Posted by "Pierre-Arnaud Marcelot (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DIRSERVER-1647?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13091850#comment-13091850 ] 

Pierre-Arnaud Marcelot commented on DIRSERVER-1647:
---------------------------------------------------

Hi again,

I thought that any schema enablement/disablement required a restart of the server.... And I was wrong...
Emmanuel, another Directory project developer, just told me that schema management is dynamic and it is perfectly allowed to enable/disable a schema without restarting the schema.

So I tried another time without ever restarting the server.

I came to a situation where I think another different bug report could be raised but I could not reproduce the exact same issue you're facing.

Here's what I did:
- Download and unzip a fresh version of ApacheDS 2.0.0-M2 as a ZIP archive. 
- Remove the "m-disabled: true" value from the NIS schema entry. 
- Create an PosixGroup entry 
- Add the "m-disabled: true" value back to the NIS schema entry.
=> This passed without any issue.
I think it's a big mistake because in that case the database becomes not coherent and you have entries relying on disabled schemas (and maybe schemas that have been removed/destroyed).
==> Leaving the server in that situation will make completely un-restartable... Which is quite bad...
IMO, a check should occur before disabling/removing a schema and it should be forbidden to do so when there are still entries depending on it.

To get back on your original issue, do you remember the exact scenario leading to the error message you're reporting?

Thanks.





> Unable to enable/modify/delete schema
> -------------------------------------
>
>                 Key: DIRSERVER-1647
>                 URL: https://issues.apache.org/jira/browse/DIRSERVER-1647
>             Project: Directory ApacheDS
>          Issue Type: Bug
>          Components: schema
>    Affects Versions: 2.0.0-M2
>            Reporter: Aaron J Angel
>
> Attempting to edit, enable, or delete a disabled schema fails with the following:
> Error while executing LDIF
>  - [LDAP: error code 53 - UNWILLING_TO_PERFORM: failed for MessageType : MODIFY_REQUES
>   javax.naming.OperationNotSupportedException: [LDAP: error code 53 - UNWILLING_TO_PERFORM: failed for MessageType : MODIFY_REQUEST
> Message ID : 22
>     Modify Request
>         Object : 'cn=nis,ou=schema'
>             Modification[0]
>                 Operation :  replace
>                 Modification
>     m-disabled: FALSE
> org.apache.directory.shared.ldap.model.message.ModifyRequestImpl@b9bf625a: ERR_11001 Cannot load the unknown schema nis]; remaining name 'cn=nis,ou=schema'
> 	at com.sun.jndi.ldap.LdapCtx.mapErrorCode(LdapCtx.java:3105)
> 	at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2978)
> 	at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2785)
> 	at com.sun.jndi.ldap.LdapCtx.c_modifyAttributes(LdapCtx.java:1468)
> 	at com.sun.jndi.toolkit.ctx.ComponentDirContext.p_modifyAttributes(ComponentDirContext.java:273)
> 	at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.modifyAttributes(PartialCompositeDirContext.java:190)
> 	at org.apache.directory.studio.connection.core.io.jndi.JNDIConnectionWrapper$2.run(JNDIConnectionWrapper.java:454)
> 	at org.apache.directory.studio.connection.core.io.jndi.JNDIConnectionWrapper.runAndMonitor(JNDIConnectionWrapper.java:1272)
> 	at org.apache.directory.studio.connection.core.io.jndi.JNDIConnectionWrapper.checkConnectionAndRunAndMonitor(JNDIConnectionWrapper.java:1203)
> 	at org.apache.directory.studio.connection.core.io.jndi.JNDIConnectionWrapper.modifyEntry(JNDIConnectionWrapper.java:502)
> 	at org.apache.directory.studio.ldapbrowser.core.jobs.ImportLdifJob.importLdifRecord(ImportLdifJob.java:507)
> 	at org.apache.directory.studio.ldapbrowser.core.jobs.ImportLdifJob.importLdif(ImportLdifJob.java:267)
> 	at org.apache.directory.studio.ldapbrowser.core.jobs.ExecuteLdifRunnable.run(ExecuteLdifRunnable.java:143)
> 	at org.apache.directory.studio.ldapbrowser.core.jobs.UpdateEntryRunnable.run(UpdateEntryRunnable.java:58)
> 	at org.apache.directory.studio.connection.ui.RunnableContextRunner$1.run(RunnableContextRunner.java:113)
> 	at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:121)
>   [LDAP: error code 53 - UNWILLING_TO_PERFORM: failed for MessageType : MODIFY_REQUEST
> Message ID : 22
>     Modify Request
>         Object : 'cn=nis,ou=schema'
>             Modification[0]
>                 Operation :  replace
>                 Modification
>     m-disabled: FALSE
> org.apache.directory.shared.ldap.model.message.ModifyRequestImpl@b9bf625a: ERR_11001 Cannot load the unknown schema nis]
> Upon installation, the nis schema was enabled by removing the m-disabled attribute from the entry.  Upon discovering that posixGroup was STRUCTURAL, I disabled the nis schema.  Now, when trying to modify the objectClass entry for posixGroup, or even when attempting to delete the nis schema entirely to start over, the above error message is presented in Directory Studio.
> For my application, I need to edit or replace the default nis schema with one compatible with rfc2307bis (e.g., posixGroup must be AUXILIARY, not STRUCTURAL).

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (DIRSERVER-1647) Unable to enable/modify/delete schema

Posted by "Pierre-Arnaud Marcelot (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DIRSERVER-1647?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13091841#comment-13091841 ] 

Pierre-Arnaud Marcelot commented on DIRSERVER-1647:
---------------------------------------------------

Hi Aaron,

I was not able to reproduce the issue.

Here's the scenario I used:
- Download and unzip a fresh version of ApacheDS 2.0.0-M2 as a ZIP archive.
- Launch the server
- Remove the "m-disabled: true" value from the NIS schema entry.
- Restart the server
- Create an PosixGroup entry
- Add the "m-disabled: true" value back to the NIS schema entry.
- Restart the server
=> Restart fails which is normal since the PosixGroup entry is still present in the DIT.
=> Edit by hand of the corresponding LDIF file on disk to remove the "m-disabled: true" from the NIS schema entry.
=> Restart the server again (successfully this time).
- Remove the PosixGroup entry
- Add the "m-disabled: true" value back to the NIS schema entry.
- Restart the server

==> Conclusion: Everything behaves as expected...

I think you probably forgot to restart the server after each time you enable/disable a schema.

Now, you probably shouldn't be able to add the posix group entry until the server has been restarted.
I will check that case...

> Unable to enable/modify/delete schema
> -------------------------------------
>
>                 Key: DIRSERVER-1647
>                 URL: https://issues.apache.org/jira/browse/DIRSERVER-1647
>             Project: Directory ApacheDS
>          Issue Type: Bug
>          Components: schema
>    Affects Versions: 2.0.0-M2
>            Reporter: Aaron J Angel
>
> Attempting to edit, enable, or delete a disabled schema fails with the following:
> Error while executing LDIF
>  - [LDAP: error code 53 - UNWILLING_TO_PERFORM: failed for MessageType : MODIFY_REQUES
>   javax.naming.OperationNotSupportedException: [LDAP: error code 53 - UNWILLING_TO_PERFORM: failed for MessageType : MODIFY_REQUEST
> Message ID : 22
>     Modify Request
>         Object : 'cn=nis,ou=schema'
>             Modification[0]
>                 Operation :  replace
>                 Modification
>     m-disabled: FALSE
> org.apache.directory.shared.ldap.model.message.ModifyRequestImpl@b9bf625a: ERR_11001 Cannot load the unknown schema nis]; remaining name 'cn=nis,ou=schema'
> 	at com.sun.jndi.ldap.LdapCtx.mapErrorCode(LdapCtx.java:3105)
> 	at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2978)
> 	at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2785)
> 	at com.sun.jndi.ldap.LdapCtx.c_modifyAttributes(LdapCtx.java:1468)
> 	at com.sun.jndi.toolkit.ctx.ComponentDirContext.p_modifyAttributes(ComponentDirContext.java:273)
> 	at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.modifyAttributes(PartialCompositeDirContext.java:190)
> 	at org.apache.directory.studio.connection.core.io.jndi.JNDIConnectionWrapper$2.run(JNDIConnectionWrapper.java:454)
> 	at org.apache.directory.studio.connection.core.io.jndi.JNDIConnectionWrapper.runAndMonitor(JNDIConnectionWrapper.java:1272)
> 	at org.apache.directory.studio.connection.core.io.jndi.JNDIConnectionWrapper.checkConnectionAndRunAndMonitor(JNDIConnectionWrapper.java:1203)
> 	at org.apache.directory.studio.connection.core.io.jndi.JNDIConnectionWrapper.modifyEntry(JNDIConnectionWrapper.java:502)
> 	at org.apache.directory.studio.ldapbrowser.core.jobs.ImportLdifJob.importLdifRecord(ImportLdifJob.java:507)
> 	at org.apache.directory.studio.ldapbrowser.core.jobs.ImportLdifJob.importLdif(ImportLdifJob.java:267)
> 	at org.apache.directory.studio.ldapbrowser.core.jobs.ExecuteLdifRunnable.run(ExecuteLdifRunnable.java:143)
> 	at org.apache.directory.studio.ldapbrowser.core.jobs.UpdateEntryRunnable.run(UpdateEntryRunnable.java:58)
> 	at org.apache.directory.studio.connection.ui.RunnableContextRunner$1.run(RunnableContextRunner.java:113)
> 	at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:121)
>   [LDAP: error code 53 - UNWILLING_TO_PERFORM: failed for MessageType : MODIFY_REQUEST
> Message ID : 22
>     Modify Request
>         Object : 'cn=nis,ou=schema'
>             Modification[0]
>                 Operation :  replace
>                 Modification
>     m-disabled: FALSE
> org.apache.directory.shared.ldap.model.message.ModifyRequestImpl@b9bf625a: ERR_11001 Cannot load the unknown schema nis]
> Upon installation, the nis schema was enabled by removing the m-disabled attribute from the entry.  Upon discovering that posixGroup was STRUCTURAL, I disabled the nis schema.  Now, when trying to modify the objectClass entry for posixGroup, or even when attempting to delete the nis schema entirely to start over, the above error message is presented in Directory Studio.
> For my application, I need to edit or replace the default nis schema with one compatible with rfc2307bis (e.g., posixGroup must be AUXILIARY, not STRUCTURAL).

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (DIRSERVER-1647) Unable to enable/modify/delete schema

Posted by "Emmanuel Lecharny (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DIRSERVER-1647?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Emmanuel Lecharny updated DIRSERVER-1647:
-----------------------------------------

    Fix Version/s: 2.0.0-M3

> Unable to enable/modify/delete schema
> -------------------------------------
>
>                 Key: DIRSERVER-1647
>                 URL: https://issues.apache.org/jira/browse/DIRSERVER-1647
>             Project: Directory ApacheDS
>          Issue Type: Bug
>          Components: schema
>    Affects Versions: 2.0.0-M2
>            Reporter: Aaron J Angel
>             Fix For: 2.0.0-M3
>
>
> Attempting to edit, enable, or delete a disabled schema fails with the following:
> Error while executing LDIF
>  - [LDAP: error code 53 - UNWILLING_TO_PERFORM: failed for MessageType : MODIFY_REQUES
>   javax.naming.OperationNotSupportedException: [LDAP: error code 53 - UNWILLING_TO_PERFORM: failed for MessageType : MODIFY_REQUEST
> Message ID : 22
>     Modify Request
>         Object : 'cn=nis,ou=schema'
>             Modification[0]
>                 Operation :  replace
>                 Modification
>     m-disabled: FALSE
> org.apache.directory.shared.ldap.model.message.ModifyRequestImpl@b9bf625a: ERR_11001 Cannot load the unknown schema nis]; remaining name 'cn=nis,ou=schema'
> 	at com.sun.jndi.ldap.LdapCtx.mapErrorCode(LdapCtx.java:3105)
> 	at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2978)
> 	at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2785)
> 	at com.sun.jndi.ldap.LdapCtx.c_modifyAttributes(LdapCtx.java:1468)
> 	at com.sun.jndi.toolkit.ctx.ComponentDirContext.p_modifyAttributes(ComponentDirContext.java:273)
> 	at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.modifyAttributes(PartialCompositeDirContext.java:190)
> 	at org.apache.directory.studio.connection.core.io.jndi.JNDIConnectionWrapper$2.run(JNDIConnectionWrapper.java:454)
> 	at org.apache.directory.studio.connection.core.io.jndi.JNDIConnectionWrapper.runAndMonitor(JNDIConnectionWrapper.java:1272)
> 	at org.apache.directory.studio.connection.core.io.jndi.JNDIConnectionWrapper.checkConnectionAndRunAndMonitor(JNDIConnectionWrapper.java:1203)
> 	at org.apache.directory.studio.connection.core.io.jndi.JNDIConnectionWrapper.modifyEntry(JNDIConnectionWrapper.java:502)
> 	at org.apache.directory.studio.ldapbrowser.core.jobs.ImportLdifJob.importLdifRecord(ImportLdifJob.java:507)
> 	at org.apache.directory.studio.ldapbrowser.core.jobs.ImportLdifJob.importLdif(ImportLdifJob.java:267)
> 	at org.apache.directory.studio.ldapbrowser.core.jobs.ExecuteLdifRunnable.run(ExecuteLdifRunnable.java:143)
> 	at org.apache.directory.studio.ldapbrowser.core.jobs.UpdateEntryRunnable.run(UpdateEntryRunnable.java:58)
> 	at org.apache.directory.studio.connection.ui.RunnableContextRunner$1.run(RunnableContextRunner.java:113)
> 	at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:121)
>   [LDAP: error code 53 - UNWILLING_TO_PERFORM: failed for MessageType : MODIFY_REQUEST
> Message ID : 22
>     Modify Request
>         Object : 'cn=nis,ou=schema'
>             Modification[0]
>                 Operation :  replace
>                 Modification
>     m-disabled: FALSE
> org.apache.directory.shared.ldap.model.message.ModifyRequestImpl@b9bf625a: ERR_11001 Cannot load the unknown schema nis]
> Upon installation, the nis schema was enabled by removing the m-disabled attribute from the entry.  Upon discovering that posixGroup was STRUCTURAL, I disabled the nis schema.  Now, when trying to modify the objectClass entry for posixGroup, or even when attempting to delete the nis schema entirely to start over, the above error message is presented in Directory Studio.
> For my application, I need to edit or replace the default nis schema with one compatible with rfc2307bis (e.g., posixGroup must be AUXILIARY, not STRUCTURAL).

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira