Could not compose a RT vApp for vApp replication with id 'C4VAPP-########-####-####-####-########996f.
/opt/vmware/h4/cloud/log/cloud.log
file on the destination Cloud Director Replication Management Appliance, you see entries similar to:2024-04-08 06:12:11.068 ERROR - [UI-########-####-####-####-########fecc-r1898-CT] [job-68] com.vmware.h4.cloud.service.RtVmService : Failed to recompose vapp.
com.vmware.vcloud.client.exception.VcloudException: (Major code = 403, minor code = ACCESS_TO_RESOURCE_IS_FORBIDDEN) - [ UI-########-####-####-####-########fecc-r1898-CT-########-####-####-####-########f268 ] Either you need some or all of the following rights [Base] to perform operations [VAPP_VIEW] for ########-####-####-####-########6a76 or the target entity is invalid.
at com.vmware.vcloud.client.VcloudClient.lambda$defaultErrorDeserializer$0(VcloudClient.java:297)
at com.vmware.rest.client.AbstractRestClient.convert(AbstractRestClient.java:227)
at com.vmware.vcloud.client.XmlRestClient.exchange(XmlRestClient.java:106)
at com.vmware.vcloud.client.XmlRestClient.exchange(XmlRestClient.java:72)
at com.vmware.vcloud.client.VcloudClient.exchange(VcloudClient.java:258)
at com.vmware.vcloud.client.VcloudClient._recomposeVapp(VcloudClient.java:808)
at com.vmware.h4.cloud.service.RtVmService.moveVmIntoVApp(RtVmService.java:355)
...
2024-04-08 06:12:11.068 ERROR - [UI-########-####-####-####-########fecc-r1898-CT] [job-68] com.vmware.h4.jobengine.JobExecution : Task ########-####-####-####-########3f6f (WorkflowInfo{type='start', resourceType='vmReplication', resourceId='C4-########-####-####-####-########1b5a', isPrivate=false, resourceName='null'}) has failed
com.vmware.h4.cloud.api.exceptions.FailedToComposeRTVApp: Could not compose a RT vApp for vApp replication with id 'C4VAPP-########-####-####-####-########996f.
at com.vmware.h4.cloud.service.RtVmService.composeRtVapp(RtVmService.java:337)
at com.vmware.h4.cloud.job.VmReplicationJob.recomposeRtVapp(VmReplicationJob.java:984)
at com.vmware.h4.cloud.job.VmReplicationJob.constructRtVApp(VmReplicationJob.java:975)
...
Note: The preceding log excerpts are only examples. Date, time, and environmental variables may vary depending on your environment.
This issue occurs when there is a stale Replication Tracking vApp (RT vApp) that is in an invalid state which prevents Replication Tracking VMs (RT VMs) from being added to it while grouping a VM replication with an existing vApp replication.
To resolve this issue, delete the stale RT vApp from Cloud Director (VCD) and then configure the VM replication again, grouping it with the existing vApp replication.
GET https://vcd.example.com/api/vApp/vapp-<RT vApp ID>
Authorization:Bearer <VCD access token>
Accept:application/*+xml;version=<VCD API version>
DELETE https://vcd.example.com/api/vApp/vapp-<RT vApp ID>
Authorization:Bearer <VCD access token>
Accept:application/*+xml;version=<VCD API version>
For more information about using the Cloud Director API, see the VMware Cloud Director API Programming Guide for Service Providers.