AEM does not pick Filedatastore location properly and does not start successfully, after upgrading instance from 5.6.x to 6.x.

Issue

After upgrading an instance from 5.6.x to 6.x, AEM does not pick up the Filedatastore location properly and therefore does not start successfully. AEM reports not being able to find blobs and would not start up successfully. However, starting the instance through command line and the quickstart file starts successfully.

Environment

AEM 6.x

Cause

The RegisteredResourceList.ser file is in corrupt state, and is not allowing windows service to operate properly. On opening the RegisteredResourceList.ser, you see multiple instances of "file install". However, ideally only one instance is expected. It shows multiple configurations persistent on the repository, and hence the conflict on startup.

Resolution

  1. Stop AEM.

  2. Download com.adobe.granite.tools.fileinstallertool-1.0.2.jar from [1], and place it in the same folder as the AEM jar file.

  3. To clear all the duplicate entries and to fix any corrupt entries, run the following command.

    java -jar com.adobe.granite.tools.fileinstallertool-1.0.2.jar
  4. At this point, either of the following two scenarios happen:

    1. You get the following output, which confirms the successful removal of duplicate configurations. You can proceed further to Step 5.

      Reading installer state from crx-quickstart/launchpad/installer/RegisteredResourceList.ser
      Processing installer state...
      - removing state for fileinstallad09f60708c0fb5aee04cdf46857bff9:/opt/AEM/6.2/Vanilla6.2/crx-quickstart/install/org.apache.jackrabbit.oak.plugins.segment.SegmentNodeStoreService.config
      - removing state for fileinstallad09f60708c0fb5aee04cdf46857bff9:/opt/AEM/6.2/Vanilla6.2/crx-quickstart/install/org.apache.jackrabbit.oak.plugins.blob.datastore.FileDataStore.cfg
      Writing installer state
      Done
      
    2. The output below, which shows there was an issue reading the RegisteredResourceList.ser and therefore the tool could not open it and run against it.

      Reading installer state from crx-quickstart/launchpad/installer/RegisteredResourceList.ser
      124 [main] WARN org.apache.sling.installer.core.impl.PersistentResourceList - Unable to restore data, starting with empty list (org.apache.sling.installer.core.impl.RegisteredResourceImpl)
      java.lang.ClassNotFoundException: org.apache.sling.installer.core.impl.RegisteredResourceImpl
           at org.apache.sling.installer.core.impl.RegisteredResourceImpl.readObject(RegisteredResourceImpl.java:124)
           at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
           at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
           at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
           at java.lang.reflect.Method.invoke(Method.java:498)
           at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:1058)
           at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1909)
           at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1808)
           at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1353)
           at java.io.ObjectInputStream.readObject(ObjectInputStream.java:373)
           at org.apache.sling.installer.core.impl.EntityResourceList.readObject(EntityResourceList.java:104)
           at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
           at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
           at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
           at java.lang.reflect.Method.invoke(Method.java:498)
           at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:1058)
           at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1909)
           at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1808)
           at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1353)
           at java.io.ObjectInputStream.readObject(ObjectInputStream.java:373)
           at java.util.HashMap.readObject(HashMap.java:1396)
           at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
           at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
           at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
           at java.lang.reflect.Method.invoke(Method.java:498)
           at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:1058)
           at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1909)
           at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1808)
           at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1353)
           at java.io.ObjectInputStream.readObject(ObjectInputStream.java:373)
           at org.apache.sling.installer.core.impl.PersistentResourceList.<init>(PersistentResourceList.java:90)
           at com.adobe.granite.tools.FICleanup.main(FICleanup.java:196)
      Processing installer state...
      No fileinstall configuration found
      Done
      

      In such a case, follow these steps:

      1. Stop the AEM instance.

      2. Unregister/Delete the windows service.

      3. Ensure that the file on path /opt/AEM/6.2/Vanilla6.2/crx-quickstart/launchpad/config/org/apache/jackrabbit/oak/plugins/blob/datastore/Filedatastore.cfg has the appropriate content, that is the Absolute Paths. If not, delete this file.

      4. Ensure that the file on path /opt/AEM/6.2/Vanilla6.2/crx-quickstart/launchpad/config/org/apache/jackrabbit/oak/plugins/segment/SegmentNodeStoreService.cfg has the appropriate content, that is the Absolute Paths. If not, delete this file.

      5. Go to the /crx-quickstart/launchpad/installer directory and rename the RegisteredResourceList.ser to RegisteredResourceList.ser_old.

      6. Clear out the AEM server logs.

      7. Register the windows service.

  5. Start AEM through the windows service.

  6. It is expected that AEM now starts successfully with the appropriate configurations. To verify, check the output of [2] and see if multiple "fileinstall" paths exist.

 Adobe

Saage abi kiiremini ja hõlpsamalt

Uus kasutaja?