- NAME
-
- gcloud alpha spanner instances move - move the Cloud Spanner instance to the specified instance config
- SYNOPSIS
-
-
gcloud alpha spanner instances move
INSTANCE
--target-config
=TARGET_CONFIG
[--target-database-move-configs
=[^:^database-id
=DATABASE_ID
:kms-keys
=KEY1
,KEY2
,…]] [GCLOUD_WIDE_FLAG …
]
-
- DESCRIPTION
-
(ALPHA)
Move the Cloud Spanner instance to the specified instance config. - EXAMPLES
-
To move the Cloud Spanner instance, which has two CMEK databases db1 and db2 and
a database db3 with Google managed encryption keys, to the target instance
configuration nam3 (us-east4, us-east1, us-central1), run:
gcloud alpha spanner instances move my-instance-id --target-config=nam3 --target-database-move-configs=^:^database-id=db1:kms-keys=projects/myproject/locations/us-east4/keyRings/mykeyring/cryptoKeys/cmek-key,projects/myproject/locations/us-east1/keyRings/mykeyring/cryptoKeys/cmek-key,projects/myproject/locations/us-central1/keyRings/mykeyring/cryptoKeys/cmek-key --target-database-move-configs=^:^database-id=db2:kms-keys=projects/myproject/locations/us-east4/keyRings/mykeyring/cryptoKeys/cmek-key,projects/myproject/locations/us-east1/keyRings/mykeyring/cryptoKeys/cmek-key,projects/myproject/locations/us-central1/keyRings/mykeyring/cryptoKeys/cmek-key
- POSITIONAL ARGUMENTS
-
INSTANCE
- Cloud Spanner instance ID.
- REQUIRED FLAGS
-
--target-config
=TARGET_CONFIG
- Target Instance configuration to move the instances.
- OPTIONAL FLAGS
-
--target-database-move-configs
=[^:^database-id
=DATABASE_ID
:kms-keys
=KEY1
,KEY2
,…]-
Database level configurations for each database to be moved. Currently only used
for CMEK databases to specificy the target database KMS keys. Sets
target_database_move_configs
value.database-id
-
Required, Sets
database-id
value. kms-keys
-
Sets
kms-keys
value.
Shorthand Example:
--target-database-move-configs=database-id=string,kms-keys=string --target-database-move-configs=database-id=string,kms-keys=string
JSON Example:
--target-database-move-configs='[{"database-id": "string", "kms-keys": "string"}]'
File Example:
--target-database-move-configs=path_to_file.(yaml|json)
- GCLOUD WIDE FLAGS
-
These flags are available to all commands:
--access-token-file
,--account
,--billing-project
,--configuration
,--flags-file
,--flatten
,--format
,--help
,--impersonate-service-account
,--log-http
,--project
,--quiet
,--trace-token
,--user-output-enabled
,--verbosity
.Run
$ gcloud help
for details. - NOTES
-
This command is currently in alpha and might change without notice. If this
command fails with API permission errors despite specifying the correct project,
you might be trying to access an API with an invitation-only early access
allowlist. These variants are also available:
gcloud spanner instances move
gcloud beta spanner instances move
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-01-28 UTC.