[[["易于理解","easyToUnderstand","thumb-up"],["解决了我的问题","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["很难理解","hardToUnderstand","thumb-down"],["信息或示例代码不正确","incorrectInformationOrSampleCode","thumb-down"],["没有我需要的信息/示例","missingTheInformationSamplesINeed","thumb-down"],["翻译问题","translationIssue","thumb-down"],["其他","otherDown","thumb-down"]],["最后更新时间 (UTC):2025-09-03。"],[],[],null,["# Data residency overview\n\nThis page describes data residency for Spanner.\n\nSpanner meets data residency compliance and regulatory\nrequirements by letting you to specify the geographic locations (regions) where\nSpanner data is stored.\n\nThe following definitions apply to this page:\n\n- A *location* is a Google Cloud region or multi-region as listed on the\n [Google Cloud locations page](/about/locations).\n\n- The term *your data* is equivalent to the meaning of the term\n \"Customer Data\" in the *Data Location* item in the Google Cloud\n [General Service Terms](/terms/service-terms).\n\nData residency commitments\n--------------------------\n\nData residency commitments in Spanner differ for databases\nthat don't use [geo-partitioning](/spanner/docs/geo-partitioning) versus\ndatabases that do use geo-partitioning.\n\n### Databases that don't use geo-partitioning\n\nFor databases that don't use geo-partitioning, Spanner provides\ndata residency commitments at the database level according to the\n[Google Cloud Terms of Service](https://cloud.google.com/terms).\n\n### Databases that use geo-partitioning\n\nFor databases that use geo-partitioning, Spanner provides data\nresidency commitments at the [placement](/spanner/docs/create-manage-data-placements)\nlevel. For each placement, you can select a specific region or multi-region\nlocation as listed on the [Google Cloud locations page](/about/locations).\nSpanner stores your data at rest only within the selected region\nor multi-region with the following limitations:\n\n- A small subset of primary keys, indexed column values, and foreign key column values (for both placement and non-placement tables) are used as [split boundaries](/spanner/docs/schema-and-data-model#database-splits), which might be stored in the default placement.\n- Statistics and observability information for key ranges used for the [key visualizer](/spanner/docs/key-visualizer/getting-started), keys experiencing high [lock contention](/spanner/docs/introspection/lock-statistics), and [query statistics](/spanner/docs/introspection/query-statistics) are stored in the default placement.\n- Column-level [statistics](/spanner/docs/query-optimizer/overview#statistics-packages) used for query optimization are stored in the default placement.\n\nThe following are by design:\n\n- Placement table primary keys are used for routing traffic and might be stored in the default placement. If this is a concern, consider using [UUIDs](/spanner/docs/primary-key-default-value#universally_unique_identifier_uuid), or other keys that aren't in scope for data residency.\n- [Interleaved indexes](/spanner/docs/secondary-indexes#indexes_and_interleaving) inherit placement from the parent row. Global indexes (including keys and storing values) are placed in the default placement.\n- [Foreign keys backing indexes](/spanner/docs/foreign-keys/overview#backing-indexes) are placed in the default placement.\n- If you change the placement key for a row, the data move happens asynchronously. It might take hours to move the row to the new location. Even after the data is available and served from the new location, deletion of data from the old location is subject to the [Google Cloud data deletion process](/docs/security/deletion).\n\nData residency encryption\n-------------------------\n\nBy default, Spanner [encrypts customer data at rest](/docs/security/encryption/default-encryption).\nSpanner handles encryption for you without any additional actions\non your part. This option is called *Google default encryption*. By default,\nGoogle uses encryption keys from the same location as where your data resides.\n\nIf you want to control your encryption keys, then you can use\n*customer-managed encryption keys (CMEKs)* in [Cloud KMS](/kms/docs)\nwith CMEK-integrated services including Spanner. When using CMEK,\nyou must select keys in the same location as where your data resides. For more\ninformation, see [Customer-managed encryption keys (CMEK) overview](/spanner/docs/cmek)."]]