Exception in a SlingRepositoryInitializer - AEM upgrade 6.2 - 6.4 | Community
Skip to main content
ashishkhadpe
Level 3
May 16, 2019
Solved

Exception in a SlingRepositoryInitializer - AEM upgrade 6.2 - 6.4

  • May 16, 2019
  • 4 replies
  • 4200 views

Hi All,

I have completed the migration from AEM 6.2 to 6.4 successfully but when I am starting my new AEM 6.4 server I am getting below error :

16.05.2019 13:44:25.152 *ERROR* [Apache Sling Repository Startup Thread] com.adobe.granite.repository.impl.SlingRepositoryManager Exception in a SlingRepositoryInitializer, SlingRepository service registration aborted

java.lang.RuntimeException: Session.save failed: javax.jcr.security.AccessControlException: OakAccessControl0013: Duplicate ACE '/content/rep:policy/allow50' found in policy

Caused by: org.apache.jackrabbit.oak.api.CommitFailedException: OakAccessControl0013: Duplicate ACE '/content/rep:policy/allow50' found in policy

Any possible cause and solution?

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Bharath_valse

On the 6.2 instance, goto /content/rep:policy/allow50 and get the value of rep:principalName and run the below query(depending on allow or deny) to check if there are any duplicate ACLs under /content/rep:policy. Delete ACL and proceed with the upgrade.

If you are not able to delete the rep:policy node directly, remove mixins rep:rep:AccessControllable, delete the duplicate ACL and re add mixins after deletion

[1] select * from [rep:GrantACE] where [rep:principalName]='principalName'

[2] select * from [rep:DenyACE] where [rep:principalName]='principalName'

Another thought, on 6.4 you could try oak run tool [3] matching your AEM's oak version to delete the node /content/rep:policy/allow50 when AEM is not running by using the script [4] and start AEM. More details can be found on [5] - Step #3

Hope this helps!!

[3]

Maven Repository: org.apache.jackrabbit » oak-run

[4]

https://gist.githubusercontent.com/stillalex/43c49af065e3dd1fd5bf/raw/9e726a59f75b46e7b474f7ac763b0888d5a3f0c3/rmNode.gr…

[5]

Offline Compaction fails with SegmentNotFoundException & IllegalArgumentException

4 replies

Adobe Employee
May 16, 2019

Hello,

If you are able to login to web console, then try the below steps:

- Restart oak-core bundle (Stop and start from OSGI)

- Restart AEM instance.

ashishkhadpe
Level 3
May 16, 2019

No I am not able to login to web console as my server is not getting started.

joerghoh
Adobe Employee
Adobe Employee
May 16, 2019

I would assume, that this issue can be reproduced when you start a fresh migration from the same instance. Can you check that?

In parallel you should raise a ticket with Adobe support, as this is a part of the migration process, and this should work ootb.

Bharath_valse
Bharath_valseAccepted solution
Level 4
May 16, 2019

On the 6.2 instance, goto /content/rep:policy/allow50 and get the value of rep:principalName and run the below query(depending on allow or deny) to check if there are any duplicate ACLs under /content/rep:policy. Delete ACL and proceed with the upgrade.

If you are not able to delete the rep:policy node directly, remove mixins rep:rep:AccessControllable, delete the duplicate ACL and re add mixins after deletion

[1] select * from [rep:GrantACE] where [rep:principalName]='principalName'

[2] select * from [rep:DenyACE] where [rep:principalName]='principalName'

Another thought, on 6.4 you could try oak run tool [3] matching your AEM's oak version to delete the node /content/rep:policy/allow50 when AEM is not running by using the script [4] and start AEM. More details can be found on [5] - Step #3

Hope this helps!!

[3]

Maven Repository: org.apache.jackrabbit » oak-run

[4]

https://gist.githubusercontent.com/stillalex/43c49af065e3dd1fd5bf/raw/9e726a59f75b46e7b474f7ac763b0888d5a3f0c3/rmNode.gr…

[5]

Offline Compaction fails with SegmentNotFoundException & IllegalArgumentException