Issue
- Successfully upgraded the Liferay portal from 6.2EE to DXP 7.1 GA but the server is not started and thrown the NPE
- Null pointer Exception:
2019-09-13 01:11:59.750 ERROR [http-nio-8080-exec-1][MainServlet:1225] com.liferay.portal.kernel.events.ActionException: java.lang.NullPointerException
com.liferay.portal.kernel.events.ActionException: java.lang.NullPointerException
- Along with NPE, Multiple exceptions are thrown as below
2019-09-13 06:50:42.608 ERROR [main][UserPersonalSitePermissions:154] Unable to get user personal site group in company 10153
com.liferay.portal.kernel.exception.NoSuchGroupException: No Group exists with the key {companyId=10153, classNameId=10187, classPK=6467801}
at com.liferay.portal.service.persistence.impl.GroupPersistenceImpl.findByC_C_C(GroupPersistenceImpl.java:6350)
at com.liferay.portal.service.impl.GroupLocalServiceImpl.getUserPersonalSiteGroup(GroupLocalServiceImpl.java:2264)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
ERROR [main][MainServlet:273] java.lang.RuntimeException: You must first upgrade to Liferay Portal 7110
java.lang.RuntimeException: You must first upgrade to Liferay Portal 7110
at com.liferay.portal.tools.DBUpgrader.checkRequiredBuildNumber(DBUpgrader.java:87)
Environment
- Liferay portal 6.2EE using latest fix pack [liferay-fix-pack-portal-170-6210 is the latest fix pack when creating this article]
- Liferay DXP 7.1 GA1
Resolution
- Following the below steps, the server gets started smoothly
- Delete the contents of $LIFERAY_HOME/osgi/state folder under {$LIFERAY_HOME} folder
- Clear the temp, work folders under the TOMCAT_HOME folder
- Please ensure that you have cleared the cache of the web browser as well
- Restart the server once cleared the temporary directories [cache]