Stay organized with collections
Save and categorize content based on your preferences.
Google Distributed Cloud (GDC) air-gapped offers you the ability to configure maintenance
windows to schedule times for automatic updates. Maintenance windows are
designed to target times where a brief downtime causes the lowest impact to your
database clusters. You can schedule maintenance windows based on day of the week
and hour, and length in which the maintenance window is open. For example, you
could set a maintenance window to start at 3:00 AM on Tuesdays that spans eight
hours.
You can also plan maintenance exclusions, which prevents disruptions to your
workloads during date ranges where, due to unique circumstances, you don't
want to allow the set maintenance window.
Create a maintenance window
To create a maintenance window for your database cluster, complete the
following steps:
Console
From the navigation menu of the GDC console, choose Database
Service.
Select the database cluster that you want to plan maintenance settings
for.
In the Maintenance section, click
editEdit.
Select the Start time and Length for the maintenance window. Also
select the days of the week to apply the maintenance window for.
To apply a maintenance exclusion, click Add Maintenance Exclusion.
Give the exclusion a name and define the time window to exclude for
your maintenance window.
Click Save.
gdcloud
To create a maintenance window for your database cluster, run:
PROJECT_ID: The ID of the project in which
to create the maintenance policy.
DAYS_OF_WEEK: Comma-separated list of days
of the week when maintenance can begin. Accepted values are RFC-822
formatted days of the week, such as Mon.
START_TIME: The time of the day, in UTC
timezone, when maintenance can begin. The value must follow the
hh:mm format, such as 20:36.
DURATION: The maximum duration that the
maintenance can last for, such as 2h3m.
To apply a maintenance exclusion to your maintenance window, run:
PROJECT_ID: The ID of the project in which
to create the maintenance policy.
EXCLUSION_NAME: The name of the new
maintenance exclusion to add.
START_TIME: The start date and time for the
new maintenance exclusion. Accepted values must follow the RFC-3339
formatted timestamp, such as 2006-01-02T15:04:05Z.
END_TIME: The end date and time for the new
maintenance exclusion. Accepted values must follow the RFC-3339
formatted timestamp, such as 2006-01-02T15:04:05Z.
Verify the maintenance policy exists and reflects your intended
configuration:
gdcloudmaintenancepolicieslist--projectPROJECT_ID
To attach the maintenance policy to your database cluster, run:
POLICY_BINDING_NAME: The name of the policy
binding resource.
PROJECT_ID: The ID of the project in which to
create the maintenance policy.
POLICY_NAME: The name of the maintenance
policy created in the previous step.
RESOURCE_NAME: The resource name to bind to.
For example, for a database cluster name my-cluster, the resource
name for each of the available database engines would be the following:
POLICY_BINDING_NAME: The name of the maintenance
policy binding.
PROJECT_ID: The ID of the project in which
the maintenance policy exists.
Manage maintenance exclusions
If you created a maintenance exclusion for your maintenance window, you can edit
or remove the exclusion without affecting the maintenance window. To edit or
remove a maintenance exclusion, complete the following steps:
Console
From the navigation menu of the GDC console, choose Database
Service.
Select the database cluster that you want to manage a maintenance
exclusion for.
In the Maintenance section, click
editEdit.
Edit the date ranges and start times of the exclusion. If you want to
delete the exclusion, click
deleteDelete.
Click Save to save your maintenance exclusion modifications to the
maintenance window.
gdcloud
The gdcloud CLI only supports adding and deleting maintenance
exclusions. Therefore, you must delete the existing exclusion and add a new
one if you want to modify your exclusion date range or times.
PROJECT_ID: The ID of the project in which
the maintenance policy exists.
EXCLUSION_NAME: The name of the new
maintenance exclusion to add.
START_TIME: The start date and time for the
new maintenance exclusion. Accepted values must follow the RFC-3339
formatted timestamp, such as 2006-01-02T15:04:05Z.
END_TIME: The end date and time for the new
maintenance exclusion. Accepted values must follow the RFC-3339
formatted timestamp, such as 2006-01-02T15:04:05Z.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-25 UTC."],[],[],null,["# Plan maintenance windows\n\nGoogle Distributed Cloud (GDC) air-gapped offers you the ability to configure maintenance\nwindows to schedule times for automatic updates. Maintenance windows are\ndesigned to target times where a brief downtime causes the lowest impact to your\ndatabase clusters. You can schedule maintenance windows based on day of the week\nand hour, and length in which the maintenance window is open. For example, you\ncould set a maintenance window to start at 3:00 AM on Tuesdays that spans eight\nhours.\n\nYou can also plan maintenance exclusions, which prevents disruptions to your\nworkloads during date ranges where, due to unique circumstances, you don't\nwant to allow the set maintenance window.\n\nCreate a maintenance window\n---------------------------\n\nTo create a maintenance window for your database cluster, complete the\nfollowing steps: \n\n### Console\n\n1. From the navigation menu of the GDC console, choose **Database\n Service**.\n\n2. Select the database cluster that you want to plan maintenance settings\n for.\n\n3. In the **Maintenance** section, click\n edit **Edit**.\n\n4. Select the **Start time** and **Length** for the maintenance window. Also\n select the days of the week to apply the maintenance window for.\n\n | **Important:** Due to other possible processes running when the maintenance window opens for your database cluster, automatic updates for your database cluster could have a delayed start. The maintenance window length defines when the maintenance processes can start. After maintenance on the database cluster starts, the process runs until completion, possibly running past the defined maintenance window.\n\n5. To apply a maintenance exclusion, click **Add Maintenance Exclusion**.\n\n6. Give the exclusion a name and define the time window to exclude for\n your maintenance window.\n\n7. Click **Save**.\n\n### gdcloud\n\n1. To create a maintenance window for your database cluster, run:\n\n gdcloud maintenance policies create \u003cvar translate=\"no\"\u003ePOLICY_NAME\u003c/var\u003e \\\n --project \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e \\\n --weekly-cycle-days \u003cvar translate=\"no\"\u003eDAYS_OF_WEEK\u003c/var\u003e \\\n --weekly-cycle-start-time \u003cvar translate=\"no\"\u003eSTART_TIME\u003c/var\u003e \\\n --weekly-cycle-duration \u003cvar translate=\"no\"\u003eDURATION\u003c/var\u003e\n\n Replace the following:\n - \u003cvar translate=\"no\"\u003ePOLICY_NAME\u003c/var\u003e: The name of the maintenance policy.\n - \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e: The ID of the project in which to create the maintenance policy.\n - \u003cvar translate=\"no\"\u003eDAYS_OF_WEEK\u003c/var\u003e: Comma-separated list of days of the week when maintenance can begin. Accepted values are RFC-822 formatted days of the week, such as `Mon`.\n - \u003cvar translate=\"no\"\u003eSTART_TIME\u003c/var\u003e: The time of the day, in UTC timezone, when maintenance can begin. The value must follow the `hh:mm` format, such as `20:36`.\n - \u003cvar translate=\"no\"\u003eDURATION\u003c/var\u003e: The maximum duration that the maintenance can last for, such as `2h3m`.\n2. To apply a maintenance exclusion to your maintenance window, run:\n\n gdcloud maintenance policies update \u003cvar translate=\"no\"\u003ePOLICY_NAME\u003c/var\u003e \\\n --project \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e \\\n --add-exclusion-name \u003cvar translate=\"no\"\u003eEXCLUSION_NAME\u003c/var\u003e \\\n --add-exclusion-start \u003cvar translate=\"no\"\u003eSTART_TIME\u003c/var\u003e \\\n --add-exclusion-end \u003cvar translate=\"no\"\u003eEND_TIME\u003c/var\u003e\n\n Replace the following:\n - \u003cvar translate=\"no\"\u003ePOLICY_NAME\u003c/var\u003e: The name of the maintenance policy.\n - \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e: The ID of the project in which to create the maintenance policy.\n - \u003cvar translate=\"no\"\u003eEXCLUSION_NAME\u003c/var\u003e: The name of the new maintenance exclusion to add.\n - \u003cvar translate=\"no\"\u003eSTART_TIME\u003c/var\u003e: The start date and time for the new maintenance exclusion. Accepted values must follow the RFC-3339 formatted timestamp, such as `2006-01-02T15:04:05Z`.\n - \u003cvar translate=\"no\"\u003eEND_TIME\u003c/var\u003e: The end date and time for the new maintenance exclusion. Accepted values must follow the RFC-3339 formatted timestamp, such as `2006-01-02T15:04:05Z`.\n3. Verify the maintenance policy exists and reflects your intended\n configuration:\n\n gdcloud maintenance policies list --project \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e\n\n4. To attach the maintenance policy to your database cluster, run:\n\n gdcloud maintenance policy-bindings create \u003cvar translate=\"no\"\u003ePOLICY_BINDING_NAME\u003c/var\u003e \\\n --project \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e \\\n --policy-name \u003cvar translate=\"no\"\u003ePOLICY_NAME\u003c/var\u003e \\\n --resource-name \u003cvar translate=\"no\"\u003eRESOURCE_NAME\u003c/var\u003e\n\n Replace the following:\n - \u003cvar translate=\"no\"\u003ePOLICY_BINDING_NAME\u003c/var\u003e: The name of the policy binding resource.\n - \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e: The ID of the project in which to create the maintenance policy.\n - \u003cvar translate=\"no\"\u003ePOLICY_NAME\u003c/var\u003e: The name of the maintenance policy created in the previous step.\n - \u003cvar translate=\"no\"\u003eRESOURCE_NAME\u003c/var\u003e: The resource name to bind to.\n For example, for a database cluster name `my-cluster`, the resource\n name for each of the available database engines would be the following:\n\n - AlloyDB Omni: `DBCluster.alloydbomni.dbadmin.gdc.goog/my-cluster`\n - Oracle: `DBCluster.oracle.dbadmin.gdc.goog/my-cluster`\n - PostGreSQL: `DBClusters.postgresql.dbadmin.gdc.goog/my-cluster`\n5. Verify the policy binding exists, and its `Valid` condition is `True`:\n\n gdcloud maintenance policy-bindings list --project \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e\n\n Replace \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e with the ID of the project in\n which to create the maintenance policy.\n\nRemove a maintenance window\n---------------------------\n\nTo remove a maintenance window for your database cluster, complete the\nfollowing steps: \n\n### Console\n\n1. From the navigation menu of the GDC console, choose **Database\n Service**.\n\n2. Select the database cluster that you want to plan maintenance settings\n for.\n\n3. In the **Maintenance** section, click\n edit **Edit**.\n\n4. In the **Length** field, select **24h**.\n\n5. Select all the days of the week.\n\n6. Click **Save**.\n\nThis removes the defined maintenance window and allows maintenance updates\nto start at any time.\n\n### gdcloud\n\n1. To remove a maintenance window from your database cluster, run:\n\n gdcloud maintenance policies delete \u003cvar translate=\"no\"\u003ePOLICY_NAME\u003c/var\u003e \\\n --project \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e\n\n Replace the following:\n - \u003cvar translate=\"no\"\u003ePOLICY_NAME\u003c/var\u003e: The name of the maintenance policy.\n - \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e: The ID of the project in which the maintenance policy exists.\n2. Remove the maintenance policy binding from the database cluster:\n\n gdcloud maintenance policy-bindings delete \u003cvar translate=\"no\"\u003ePOLICY_BINDING_NAME\u003c/var\u003e \\\n --project \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e\n\n Replace the following:\n - \u003cvar translate=\"no\"\u003ePOLICY_BINDING_NAME\u003c/var\u003e: The name of the maintenance policy binding.\n - \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e: The ID of the project in which the maintenance policy exists.\n\nManage maintenance exclusions\n-----------------------------\n\nIf you created a maintenance exclusion for your maintenance window, you can edit\nor remove the exclusion without affecting the maintenance window. To edit or\nremove a maintenance exclusion, complete the following steps: \n\n### Console\n\n1. From the navigation menu of the GDC console, choose **Database\n Service**.\n\n2. Select the database cluster that you want to manage a maintenance\n exclusion for.\n\n3. In the **Maintenance** section, click\n edit **Edit**.\n\n4. Edit the date ranges and start times of the exclusion. If you want to\n delete the exclusion, click\n delete **Delete**.\n\n5. Click **Save** to save your maintenance exclusion modifications to the\n maintenance window.\n\n### gdcloud\n\nThe gdcloud CLI only supports adding and deleting maintenance\nexclusions. Therefore, you must delete the existing exclusion and add a new\none if you want to modify your exclusion date range or times.\n\n1. To delete a maintenance exclusion, run:\n\n gdcloud maintenance policies update \u003cvar translate=\"no\"\u003ePOLICY_NAME\u003c/var\u003e \\\n --project \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e \\\n --remove-exclusion-name \u003cvar translate=\"no\"\u003eEXCLUSION_NAME\u003c/var\u003e\n\n Replace the following:\n - \u003cvar translate=\"no\"\u003ePOLICY_NAME\u003c/var\u003e: The name of the maintenance policy.\n - \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e: The ID of the project in which to delete the maintenance policy's exclusion.\n - \u003cvar translate=\"no\"\u003eEXCLUSION_NAME\u003c/var\u003e: The name of the maintenance exclusion to delete.\n2. To add a new maintenance exclusion to apply any previous exclusion edits,\n run:\n\n gdcloud maintenance policies update \u003cvar translate=\"no\"\u003ePOLICY_NAME\u003c/var\u003e \\\n --project \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e \\\n --add-exclusion-name \u003cvar translate=\"no\"\u003eEXCLUSION_NAME\u003c/var\u003e \\\n --add-exclusion-start \u003cvar translate=\"no\"\u003eSTART_TIME\u003c/var\u003e \\\n --add-exclusion-end \u003cvar translate=\"no\"\u003eEND_TIME\u003c/var\u003e\n\n Replace the following:\n - \u003cvar translate=\"no\"\u003ePOLICY_NAME\u003c/var\u003e: The name of the maintenance policy.\n - \u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e: The ID of the project in which the maintenance policy exists.\n - \u003cvar translate=\"no\"\u003eEXCLUSION_NAME\u003c/var\u003e: The name of the new maintenance exclusion to add.\n - \u003cvar translate=\"no\"\u003eSTART_TIME\u003c/var\u003e: The start date and time for the new maintenance exclusion. Accepted values must follow the RFC-3339 formatted timestamp, such as `2006-01-02T15:04:05Z`.\n - \u003cvar translate=\"no\"\u003eEND_TIME\u003c/var\u003e: The end date and time for the new maintenance exclusion. Accepted values must follow the RFC-3339 formatted timestamp, such as `2006-01-02T15:04:05Z`."]]