This page describes how to perform view, update, and delete operations for connection profiles.
View a connection profile
You can view the following information about your connection profiles:
All configuration details provided during profile creation. For more information, see Connection profiles overview.
Connection profile creation and last modification time.
A list of migration jobs that use this connection profile.
To view connection profile details, perform the following steps:
Console
- In the Google Cloud console, go to the Connection profiles page.
- Click the display name of the connection profile that you want to view.
A connection profile overview page appears.
gcloud
Before using any of the command data below, make the following replacements:
- REGION with the identifier of the region where your connection profile is saved.
- CONNECTION_PROFILE_ID with
your connection profile identifier.
If you don't know the identifier, you can use the
gcloud database-migration connection-profiles listcommand to list all profiles in a given region and view their identifiers.
Execute the following command:
Linux, macOS, or Cloud Shell
gcloud database-migration connection-profiles \ describe CONNECTION_PROFILE_ID \ --region=REGION
Windows (PowerShell)
gcloud database-migration connection-profiles ` describe CONNECTION_PROFILE_ID ` --region=REGION
Windows (cmd.exe)
gcloud database-migration connection-profiles ^ describe CONNECTION_PROFILE_ID ^ --region=REGION
Update a connection profile
You can modify the following connection profile details:
- Display name
- For source connection profiles: hostname or IP address, port, username, password, database name, and SSL/TLS certificates
- For destination connection profiles (existing cluster only): destination AlloyDB for PostgreSQL cluster identifier
To update a connection profile, perform the following steps:
Console
- In the Google Cloud console, go to the Connection profiles page.
- Click the display name of the connection profile that you want to modify.
An overview page appears for the connection profile.
- Click Edit and update your connection profile.
- Click Save.
gcloud
Before using any of the command data below, make the following replacements:
- CONNECTION_PROFILE_ID with
your connection profile identifier.
If you don't know the identifier, you can use the
gcloud database-migration connection-profiles listcommand to list all profiles in a given region and view their identifiers. - REGION with the identifier of the region where your connection profile is saved.
- Optional: CONNECTION_PROFILE_NAME with a human-readable name for your connection profile. This value is displayed in the Google Cloud console.
- For source connection profiles: you can also pass flags such as
--host,--port,--username, and--passwordto update your source database connection details. For the full list of supported flags, see thegcloud database-migration connection-profiles updatereference. - For destination connection profiles (existing cluster only): ALLOYDB_CLUSTER_ID with the cluster identifier of your destination AlloyDB for PostgreSQL cluster. For information on how to view AlloyDB for PostgreSQL cluster details, see View cluster details in the AlloyDB for PostgreSQL documentation.
Execute the following command:
Linux, macOS, or Cloud Shell
gcloud database-migration connection-profiles \ update CONNECTION_PROFILE_ID \ --region=REGION \ --display-name=CONNECTION_PROFILE_NAME \ --alloydb-cluster=ALLOYDB_CLUSTER_ID
Windows (PowerShell)
gcloud database-migration connection-profiles ` update CONNECTION_PROFILE_ID ` --region=REGION ` --display-name=CONNECTION_PROFILE_NAME ` --alloydb-cluster=ALLOYDB_CLUSTER_ID
Windows (cmd.exe)
gcloud database-migration connection-profiles ^ update CONNECTION_PROFILE_ID ^ --region=REGION ^ --display-name=CONNECTION_PROFILE_NAME ^ --alloydb-cluster=ALLOYDB_CLUSTER_ID
Result
The action is performed in an asynchronous manner. As such, this command returns an Operation entity that represents a long-running operation:
done: false metadata: '@type': type.googleapis.com/google.cloud.clouddms.v1.OperationMetadata apiVersion: v1 createTime: '2024-02-20T12:20:24.493106418Z' requestedCancellation: false target: CONNECTION_PROFILE_ID verb: update name: OPERATION_ID
To see if your operation is successful, you can query the returned operation object, or check the connection profile details:
- Use the
gcloud database-migration connection-profiles describecommand to view the updated connection profile details. - Use the
gcloud database-migration operations describecommand with the OPERATION_ID to see the status of the operation itself.
Delete a connection profile
You can delete a connection profile only if there are no migration jobs that use that profile. If you want to delete a connection profile that is in use by a migration job, first delete all migration jobs that are linked to the connection profile.
To delete a connection profile, perform the following steps:
Console
- In the Google Cloud console, go to the Connection profiles page.
- Click the display name of the connection profile that you want to
delete.
A connection profile overview page appears.
- Click Delete.
- In the dialog, click Delete.
gcloud
This command returns an interactive confirmation prompt that requires your input to complete.
You can skip the confirmation prompt by using the
optional --quiet flag.
Before using any of the command data below, make the following replacements:
- REGION with the identifier of the region where your connection profile is saved.
- CONNECTION_PROFILE_ID with
your connection profile identifier.
If you don't know the identifier, you can use the
gcloud database-migration connection-profiles listcommand to list all profiles in a given region and view their identifiers.
Execute the following command:
Linux, macOS, or Cloud Shell
gcloud database-migration connection-profiles \ delete CONNECTION_PROFILE_ID \ --region=REGION
Windows (PowerShell)
gcloud database-migration connection-profiles ` delete CONNECTION_PROFILE_ID ` --region=REGION
Windows (cmd.exe)
gcloud database-migration connection-profiles ^ delete CONNECTION_PROFILE_ID ^ --region=REGION
The delete command returns an interactive prompt where you confirm
the action. Enter Y to remove the connection profile:
You are about to delete connection_profile [CONNECTION_PROFILE_ID] Do you want to continue (Y/n)?
--quiet flag.