Google Cloud uses DMS to shrink Cloud SQL Server disks
Tue, 17th Nov 2026 (Today)
Google Cloud has outlined a way to use its Database Migration Service to reduce storage attached to Cloud SQL for SQL Server instances with limited downtime. The approach uses continuous replication to move databases to a new instance with a smaller disk.
The method is aimed at customers whose storage footprint has fallen after archiving data, deleting old records, removing indexes or recovering from one-off spikes that triggered automatic storage expansion. In those cases, database files may shrink inside SQL Server, while the underlying Cloud SQL persistent disk remains at its previous peak size.
That can leave companies paying for storage they no longer need. Google Cloud noted that its built-in storage shrink feature can reclaim unallocated disk space, but it requires downtime that increases with the size of the allocated disk and can stretch to hours for multi-terabyte drives.
Database Migration Service, or DMS, offers an alternative by keeping a source and target Cloud SQL for SQL Server instance in sync while the production application remains online. The workload is then switched to the target during a short cutover window.
How it works
In Cloud SQL for SQL Server, DMS can use another Cloud SQL instance as a source, rather than serving only as a tool for moving workloads from on-premises systems or rival cloud platforms. The service supports replication between instances in the same project, across projects and across regions.
The replication process begins with an initial full backup of selected user databases, followed by continuous transaction log backups. Those logs are then applied to the target instance to keep it closely aligned with the source in near real time.
In practice, the workflow starts with creating a new Cloud SQL for SQL Server target instance with a smaller disk. Engineers then start a continuous DMS job from the existing instance, allow replication to catch up, stop application traffic for the final log application, and promote the target before pointing the application to the new instance.
This model is intended to reduce outage time because the lengthy storage operation takes place on the destination side while the source system continues serving production traffic. Only the final switch requires a maintenance window.
Operational limits
The process does not move every part of a SQL Server environment. Because DMS replicates at the user-database level, server-level objects such as logins, linked servers and SQL Server Agent jobs are not copied automatically.
That means database teams must prepare the destination environment before cutover. Administrators should script logins from the source, recreate them on the target, and manually deploy other server-level objects.
The same applies to several instance-level configuration items, including database flags and identity settings. In environments using Transparent Data Encryption, certificates must also be exported and imported before cutover.
Another issue can arise after the move if login security identifiers do not match those embedded in restored databases. In that case, database users become orphaned and must be remapped manually on the target system.
Cost pressure
The guidance reflects a common problem in database operations: storage tends to expand quickly but is harder to reduce once short-term demands have passed. Automatic storage growth protects production systems from running out of space during traffic surges, imports, maintenance activity or staging loads, but it can also leave long-term excess capacity behind.
Google Cloud pointed users to two monitoring metrics in Cloud Monitoring that can help identify this gap: database/disk/bytes_used, which tracks actual consumption by database files and logs, and database/disk/quota, which shows total provisioned capacity.
Engineers can also inspect allocated and used space inside SQL Server files to judge whether a disk reduction is worthwhile. Google Cloud presented the migration-based method as especially relevant where service-level commitments make a long offline shrink impractical.
The move also broadens the role of DMS from a migration product to an operational tool for workloads already running in the cloud. For database teams managing mature SQL Server estates, a service commonly associated with onboarding can also be used for storage correction without a prolonged shutdown.
The result is a way to move to a right-sized Cloud SQL for SQL Server instance while keeping the production application online for most of the process, with only a brief cutover at the end.