Modifying snapshotLimit Post-deployment in VMware Aria Automation 8.x
https://knowledge.broadcom.com/external/article?articleNumber=389946
Issue/Introduction
In VMware Aria Automation 8.x, the snapshotLimit property defines the maximum number of snapshots allowed for a deployed virtual machine. Once a deployment is created, snapshotLimit becomes a read-only property, preventing modification via API or UI.
This article provides a workaround for increasing snapshotLimit post-deployment when the limit needs to be raised.
Environment
VMware Aria Automation 8.x
Cause
- snapshotLimit is immutable after deployment and cannot be modified using API PATCH updates.
- API updates return a success code but do not actually modify the snapshotLimit value.
- Unlike other custom properties, snapshotLimit is locked in compute_state.custom_properties within the Provisioning Database.
Resolution
Prerequisites
- Ensure you have valid backups or snapshots before proceeding.
- Note: This procedure includes direct modifications to the underlying database. Do not proceed without backups or snapshots.
Procedure
- SSH into the vRA appliance and connect to the Provisioning Database:
vracli dev psql provisioning-db
- Run the following command to update snapshotLimit:
UPDATE compute_state
SET custom_properties = jsonb_set(custom_properties, '{snapshotLimit}', '"2"')
WHERE custom_properties->>'snapshotLimit' IS NOT NULL
AND name = 'Cloud_vSphere_Machine_1-mcm849-289474512219';
Note: Replace "2" with the desired snapshot limit.
Note: Replace 'Cloud_vSphere_Machine_1-mcm849-289474512219' with the actual VM name. - Verify the update:
SELECT name, custom_properties FROM compute_state
WHERE name = 'Cloud_vSphere_Machine_1-mcm849-289474512219';
- Test snapshot creation in Aria Automation.
- Expected Outcome
- The snapshot limit is successfully increased.
- Snapshots can now be created within the new limit.
Comments
Post a Comment