This page provides information about the settings available for Cloud SQL instances.
|Setting||Modifiable after creation?||Possible values|
|Instance ID||N||Composed of lowercase letters, numbers, and hyphens; must start with a letter. The total length must be 98 characters or less.|
|Zone||Y||The possible values depend on the region.|
Console string API enum string SQL Server 2017 Standard
For resource limits of these versions, see Scale Limits.
|Active Directory domain||Y||A dropdown menu for joining a managed Active Directory domain is available. The menu lists any Managed Microsoft AD domains in your project. From the dropdown menu, you can select a domain. For more information, see Overview of Managed Microsoft AD in Cloud SQL. Additionally, note the procedures and constraints for integrating with a managed AD domain in a different project.|
|Private IP||After it is enabled, it cannot be disabled.||Enabled or disabled.|
|Public IP||Y||Enabled or disabled.|
|Authorized networks||Y||If Public IP is enabled, IP addresses authorized to connect to the instance. You can also specify this value as an IP address range, in CIDR notation.|
|Cores||Y||For information about scale limits for cores, see Editions and supported features of SQL Server 2017.|
|Memory||Y||For information about scale limits for memory, see Editions and supported features of SQL Server 2017.|
SSD (only value)
Instances with at least one (unshared) vCPU can have up to 64 TB.
Note that creating or increasing storage capacity to 64 TB might increase latency of common operations, such as backups, dependent on your workload.
|Enable automatic storage increases||Y||
On (default value)
|Automatic storage increase limit||Y||In GBs. 0 (the default) means there is no limit.|
On (default value)
|Locations options||Y||Multi-region (default value)
There is also a drop-down menu with a list of multi-regions when you select Multi-region or regions when you select Region.
|Instance deletion protection||Y||Enabled or disabled.|
|Availability: Single zone||Y
||On (default value)
|High availability (regional)||Y
Off (default value)
|Maintenance: Preferred window||Y||
Any (default value)
Day of the week
|Maintenance: Order of update||Y||
Any (default value)
|Database flags||Y||See Configuring Database Flags.|
|Default collation||N||Possible values are listed at the following location: Server-level collations.|
|SQL Server Audit||Y||Enabled or disabled.|
- Instance ID
The instance ID is the name of the instance. It is used to uniquely identify your instance within the project. Choose an instance name that is aligned with the purpose of the instance when possible.
The total length ofYou do not need to include the project ID in the instance name. This is done automatically where appropriate (for example, in the log files). ...see naming guidelines
project-ID:instance-IDmust be 98 characters or less.
- The Google Cloud region where your instance is located. You can only set the region during instance creation. To improve performance, keep your data close to the services that need it. For more information, see Instance Locations.
- The Google Cloud zone where your instance is located. If you are connecting from a Compute Engine instance, select the zone where the Compute Engine instance is located. Otherwise, accept the default zone. You can edit the instance later to change the zone, if needed. For more information, see Instance Locations.
The number of CPUs for your instance.
The amount of memory available for your instance. For performance-sensitive workloads such as online transaction processing (OLTP), make sure that your instance has enough memory to contain the entire working set. However, there are other factors that can impact memory requirements, such as number of active connections. Perform load testing to avoid performance issues in production.
- Database version
- Unless you need a capability provided only by a specific version,
accept the default database version.
gcloudcommand and REST API usage, see the reference documentation.
- Storage type
- Choosing SSD, the default and only available value, provides your instance with SSD storage. SSDs provide lower latency and higher data throughput.
- Active Directory domain
You can integrate with Managed Microsoft AD, enabling Windows Authentication for the instance. To integrate, you choose a domain for the instance to join. For more information, see the Overview of Managed Microsoft AD in Cloud SQL.
- Storage capacity
Choose a capacity to fit your database size. After you have created your instance, you can manually increase the storage capacity by editing your instance configuration, but you cannot decrease it. Increasing the storage capacity does not cause downtime.
The amount of storage capacity allocated for your instance affects the cost of your instance. For more information, see Storage and Networking Pricing.
For read replicas, the storage capacity must always be at least as high as the storage capacity of the primary instance. When a primary instance is resized, all read replicas are resized, if needed, so that they have at least as much storage capacity as the updated primary instance.
- Enable automatic storage increases
If you enable this setting, Cloud SQL checks your available storage every 30 seconds. If the available storage falls below a threshold size, Cloud SQL automatically adds additional storage capacity. If the available storage repeatedly falls below the threshold size, Cloud SQL continues to add storage until it reaches the maximum of 64 TB.
The automatic storage increase setting of a primary instance automatically applies to any read replicas of that instance. The automatic storage increase setting cannot be independently set for read replicas.
The threshold size depends on the amount of storage currently provisioned for your instance; it cannot be larger than 25 GB.
For instances provisioned with 500 GB of storage (or more), the threshold is always 25 GB.
For instances provisioned with less than 500 GB of storage, this formula is used to calculate the threshold:
5 + (provisioned storage)/25
The result of the division is rounded down to the nearest whole number.
Threshold calculation for an instance with 66 GB storage capacity:
5 + (1/25th of 66 GB) = 5 + (66/25) = 5 + 2.6 -> 5 + 2 = 7 GBThreshold calculation for an instance with 1000 GB storage capacity:
5 + (1/25th of 1000 GB) = 5 + (1000/25) = 5 + 40 = 45 -> rounded down to the maximum value of 25 GB
Amount of storage added
The amount of storage added to the instance is equal to the threshold size, which cannot be larger than 25 GB.
Considerations for large disks
When automatic storage increase is enabled and the disk is large, for example greater than 1 TB, the disk remains at 99% capacity all of the time. It might seem that the disk is full but it's actually not.
Before an operation that rapidly grows disk space usage, such as a large import or a query that requires a large temp table, manually resize the disk, rather than depend on autogrow to keep up..
- Automatic storage increase limit
If you enable the automatic storage increase setting, you can provide a specific limit on how large the storage for your instance can automatically grow. Keep in mind that the bigger the size of the instance, the greater the operational latency.
You can't decrease storage size, so this limit can prevent your instance size from growing too large (due to a temporary increase in traffic). Keep in mind that when an instance becomes unable to add storage that it needs, the instance likely stops accepting incoming connections and could go offline.
Setting this limit to zero, the default value, means that there is no limit (other than the maximum available storage for the instance tier).
To set the limit when you create the instance, use the
--storage-auto-increase-limit=INTEGER_VALUE_OF_GBparameter, as described on the create instance page. To set the limit on an existing instance, use the same parameter with the
gcloud beta sql instances patchcommand.
The automatic storage increase limit setting of a primary instance automatically applies to any read replicas of that instance. The automatic storage increase limit setting cannot be independently set for read replicas.
- This setting determines whether automated backups are performed.
- Retention settings for automated backups
- The default value for the number of retained backups is 7 but you can
change it to any value in the range of 1 to 365.
See Automated backup and transaction log retention for more information.
- Location options
You can choose to store backups in multiple or single regions. Multi-region is the default, and the recommended choice because it provides protection against downtime when a region becomes unavailable. Backups are stored in regions that are closest to the instance.
You also have the option of selecting a custom location for your backup. Only use this option if required by regulation or if an organization policy requires your backups to be in specific multiple or single regions. See Custom locations for more information.
- Instance deletion protection
Protects an instance against accidental deletion. If this setting is enabled, you must disable it before deleting the instance. See Prevent deletion of an instance.
- Availability: Zonal
Puts your instance and backups in a single zone. When you select this option, there is no failover in the event of an outage. Recommended only for test and development purposes.
- High availability (regional)
When you select High availability (regional), if there is an outage, your instance fails over to another zone in the region where your instance is located, as long as the failover zone is not having an outage. It is recommended that you select High availability (regional) for instances in your production environment.
- Maintenance window
The day and hour when maintenance events for the Cloud SQL instance can be scheduled. Maintenance downtime is typically a minute or less.
Read replicas do not support maintenance window settings at this time.
For more information about maintenance, see About maintenance on Cloud SQL instances.
- Maintenance timing
Your preference about the relative order and timing of maintenance updates. Receiving updates earlier lets you test maintenance updates on a test environment before your production instances get the update. The maintenance timing setting doesn't affect the maintenance version that Cloud SQL applies to your instance.
If you don't set the maintenance timing setting, Cloud SQL chooses the timing of updates to your instance (within its maintenance window, if applicable).
For more information about maintenance, see About maintenance on Cloud SQL instances.
- Private IP
- Configures your instance to use private IP. Learn more.
- Public IP
- If enabled, your instance is allocated a public IPv4 address. When you disable Public IP, that address is released; you can reenable Public IP later, but you receive a different IPv4 address. By default, the public IP address is blocked for all addresses. Use Authorized networks to enable access.
- You can add specific IP addresses or ranges of addresses to
open your instance to those addresses.
For information about configuring IP addresses, see Configuring IP connectivity.
- Activation policy
- You change the activation policy by starting and stopping the instance. Stopping the instance prevents further instance charges.
- Database flags
You can set specific database flags on the Cloud SQL instance.
For a complete list of the database flags you can set, see Configure Database Flags.
- Default collation
You can set a default collation value for the instance, as described on the Creating instances page. This collation setting is an instance-level default for sorting rules, case, and accent sensitivity in the instance databases.
This collation setting becomes the default for the system databases, too.
A collation setting of an instance or database is indicated in the Google Cloud console. You can verify an instance's default collation on the Instance Overview page (available through the Cloud SQL Instances page). Additionally, from the Instance Overview page, in the Navigation menu, you can click Databases to verify a specific database's collation setting.
This collation default is permanent at the instance level but not at the database level. You can change this default with a database administration tool, but only for a specific database that you are creating or updating. You cannot change the collation default for an instance after creating the instance (unless you recreate the instance).
If you clone an instance, the default collation carries over to the clone.
For a complete list of the supported collation settings, see Server-level collations.
- SQL Server Audit
This setting determines if database auditing is enabled. For more information, see SQL Server database auditing.
Impact of changing instance settings
For most instance settings, Cloud SQL applies the change immediately and connectivity to the instance is unaffected.
Changing the number of CPUs or the memory size results in the instance going offline for less than 60 seconds. Changing an instance's zone, configuring the private IP, changing its network, and enabling high availability results in the instance going offline for several minutes. Plan to make these kinds of changes when your service can handle an outage of this duration.
- Learn how to edit your instance.
- Learn more about database flags.
- Learn how to authorize IP access for your instance.
- Learn more about replication options.
- See pricing for your instance.