Moving a Virtual Service Route Table Between Compartments
Move a virtual service route table to another compartment in Service Mesh.
After you move a virtual service route table to a new compartment, inherent policies apply immediately and affect access to the virtual service through the Console. For more information, see Managing Compartments.
Before you proceed, you must set up the appropriate OCI policies for the virtual service route table resource. For details, see Required IAM Policy for Virtual Service Route Table.
- Open the navigation menu and click Developer Services. Under Containers & Artifacts, click Service Mesh.
- Click Service Meshes.
- On the Service Mesh page, from the list of compartments on the left side, select a compartment.
- From the list of meshes, click the mesh name that contains the virtual service for which you want to move the route table.
- On the details page of the mesh, click the name of the virtual service.
- On the details page of the virtual service, under Resources, select Route Tables, and click the route table that you want to move.
- On the details page of the route table, click Move resource.
- In the Move resource dialog box, select the destination compartment.
- Click Move resource.
To see what operations are available for
virtual-service-route-table change-compartment
use:oci service-mesh virtual-service-route-table change-compartment -h
To move a virtual service route table using the CLI:
- Run
oci service-mesh virtual-service-route-table change-compartment
to move the virtual service route table:
oci service-mesh virtual-service-route-table change-compartment --compartment-id <compartmentId> --virtual-service-route-table-id <virtualServiceRouteTableId>
where:
<compartmentId>
: The OCID of the destination compartment for the virtual service route table.<virtualServiceRouteTableId>
: The OCID of the virtual service route table to move. To find out the virtual service route table's OCID, see Listing Virtual Service Route Tables.
For example:
oci service-mesh virtual-service-route-table change-compartment --compartment-id ocid1.compartment.oc1..aaa... --virtual-service-route-table-id ocid1.meshvirtualserviceroutetable.oc1..aaa...
The response to the command includes:
- The life cycle state (for example, ACTIVE, FAILED).
- The ID of the work request to move the virtual service route table (details of work requests are available for seven days after completion, cancellation, or failure).
If you want the command to wait to return control until the virtual service route table is active or the request has failed, include either or both of the following parameters:
--wait-for-state SUCCEEDED
--wait-for-state FAILED
For example:
oci service-mesh virtual-service-route-table change-compartment --compartment-id ocid1.compartment.oc1..aaa... --virtual-service-route-table-id ocid1.meshvirtualserviceroutetable.oc1..aaa... --wait-for-state SUCCEEDED
Tip
You can't use the virtual service until the work request has successfully created it and the virtual service is active.Checking Virtual Service Route Table Status
To see the status of the virtual service route table, enter:
oci service-mesh virtual-service-route-table get --virtual-service-route-table-id <virtualServiceRouteTableId>
To view the status of the work request creating the virtual service route table, refer to Service Mesh Work Requests.
For more information about using the CLI, see:
- Run
Use the ChangeVirtualServiceRouteTableCompartment operation to move a virtual service route table.