Restore a deleted DAM folder after a CRX package import in Adobe Experience Manager
This article explains how to restore a Digital Asset Management (DAM) folder in Adobe Experience Manager (AEM) that was deleted as a result of a CRX package import, using the pre-installation snapshot created by AEM Package Manager.
Description description
When importing a CRX package in AEM, content under a DAM path may be deleted if the package filter covers a broader path but doesn’t include the specific folder. This can result in the unintended removal of folders and their contents. The issue is typically noticed immediately after the package installation, with no error messages reported during the process. The deleted folder and its assets need to be restored to their previous state.
Environment
Adobe Experience Manager (all versions)
Symptoms
- A folder and its contents under a DAM path are deleted immediately after a CRX package import.
- No errors are reported during package installation.
- The content loss is detected right after the import.
Cause
The CRX package import replaces or removes content under the specified DAM path due to the package filter configuration. If the filter includes a parent path but not the specific folder, that folder and its descendants may be deleted. Uninstalling the package applies the pre-installation snapshot, which can restore the lost content.
Resolution resolution
Follow the steps below to resolve the issue.
-
Identify the package installation that coincided with the deletion event:
-
Review AEM Package Manager logs to determine which package was installed at the time the folder was deleted.
-
Confirm the package name and installation time.
-
-
Locate the pre-installation snapshot associated with the package:
-
In AEM, pre-installation snapshots are typically stored under
/etc/packages. -
Find the snapshot that matches the package and installation time.
-
-
Validate the snapshot:
-
Extract and review the snapshot to ensure it contains the deleted folder and its serialized content.
-
Confirm with stakeholders that the snapshot matches the expected state.
-
-
Restore the content:
-
Uninstall the original package using AEM Package Manager.
-
The uninstall operation applies the pre-installation snapshot, restoring the deleted folder and its contents.
-
Don’t install the extracted snapshot package directly unless specifically required; use the uninstall operation to trigger the snapshot restore.
-
-
Verify restoration:
-
Confirm that the folder and all expected assets are present and correct under the original path.
-
Communicate with stakeholders to validate the restoration.
-