Post upgrade from AEM 6.2 with SP2 to AEM 6.4 few of the packages are in not installed. The older version is on installed state.
For the new package is showing the message as "A different version seems to be installed:"
When i am trying to install manually i am getting the error javax.jcr.nodetype.ConstraintViolationException: OakConstraint0074: Attempt to add, modify or remove the system maintained property 'rep:externalId' and the package is not able install.
This is because of upgrade is not done properly. During the upgrade few packages is not upgraded from older version to new version due to javax.jcr.nodetype.ConstraintViolationException. This is because of custom code has updated 'rep:externalId' to the users and system user in the AEM 6.2 instance. During the upgrade this properly in the System user creates javax.jcr.nodetype.ConstraintViolationException. So i have deleted this property from system user before upgrade. This works for the above problem.
**Note :** Since Oak 1.5.8 the system-maintained property rep:externalId is protected and can not be altered using regular JCR and Jackrabbit API, irrespective of the permission setup of the editing session.
I don't believe SP2 was released for 6.2.Also, in the upgrade plannig, there is a following note which provdes the minimum patch details required to perform a successfull upgrade.
If you are upgrading from AEM 6.2 to 6.3, you should EITHER upgrade from versions (6.2-SP1-CFP1 - -6.2SP1-CFP12.1) or 6.2SP1-CFP15onwards. Otherwise, if you are upgrading from 6.2SP1-CFP13/6.2SP1CFP14 to AEM 6.3, you must also upgrade to at least version 126.96.36.199. Otherwise, AEM Sites would fail after upgrading.