What happens to Amazon RDS and Amazon Redshift queries that are running during a maintenance window?

2 minute read

I have Amazon Relational Database Service (Amazon RDS) or Amazon Redshift queries that are running during a maintenance window. What happens to queries that are running during a maintenance window?


Amazon RDS maintenance

Amazon RDS maintenance windows usually involve updates to the DB instance's operating system (OS), to the database engine version, or to the cluster version. If maintenance requires an instance reboot or an engine restart, then queries and transactions that are running are terminated and uncommitted transactions are rolled back during the engine restart to ensure Atomicity, Consistency, Isolation, and Durability (ACID) compliance. You must re-run the queries or transactions that are terminated. By default, both MySQL and PostgreSQL are ACID compliant, but it can be overridden by some parameter configurations. Check your engine's documentation to confirm that you don't have any parameters that would stop the engine from being ACID compliant. For more information, see the MySQL documentation for InnoDB and the ACID Model and the PostgreSQL documentation for synchronous_commit.

Amazon Redshift maintenance

Amazon Redshift maintenance windows require the cluster to go offline or to restart during scheduled maintenance. If queries are running during scheduled maintenance, then queries are terminated and rolled back. To view which queries were terminated, see SVL_QLOG. It's a best practice to schedule around maintenance windows—especially long-running operations, such as large data loads or VACUUM operations. For more information, see Amazon Redshift best practices.

Note: If the maintenance doesn't require a restart for the DB engine, cluster, or instance, then queries are not affected.

Related information

Maintaining a DB Instance

How do I configure notifications for Amazon RDS or Amazon Redshift maintenance windows?

How do I minimize downtime during required Amazon RDS maintenance?

AWS OFFICIALUpdated 3 years ago