- Newest
- Most votes
- Most comments
This behavior you're experiencing with your Aurora Serverless v2 database is not uncommon, even when there's no apparent user activity. Several factors could be causing your database to resume and pause regularly:
-
Maintenance actions: Aurora may perform various background tasks, such as upgrades, configuration changes, or log file downloads, which can prevent pausing or trigger resuming.
-
Continuous backup processes: If the Aurora storage system is still applying storage changes to catch up to the current point in time, this can keep the writer instance from pausing or cause it to resume.
-
Internal processes: PostgreSQL may have engine-specific scheduled jobs or internal processes that periodically activate, causing the instance to resume.
-
Replication: If your database has engine-specific replication enabled, this can prevent the instance from pausing or cause it to resume.
-
Transient communication issues: In rare cases, if Aurora can't determine the current minimum capacity setting, it may not pause the instance or may resume it.
-
RDS Proxy: If you have an RDS Proxy set up, it could also cause this behavior.
To troubleshoot this issue:
- Check your database logs more thoroughly for any patterns or recurring events coinciding with the resume times.
- Review your DB parameter group settings for any configurations that might be triggering periodic activities.
- Examine any applications or tools that might be configured to connect to your database automatically.
- Consider setting up more detailed CloudWatch alarms to capture any subtle patterns in resource utilization or connection attempts just before the resumes.
If you're unable to identify the cause through these methods, it would be advisable to open a support case with AWS. They have access to more detailed system logs and may be able to provide insight into any internal processes or issues causing these unexpected resumes.
Remember that while the auto-pause feature can help reduce costs, it's designed with a balance between cost savings and quick availability. For a development environment, you might also consider stopping the instance manually when not in use for extended periods, although this would result in longer startup times when you need to use it again.
Sources
Aurora Serverless v2 resumes without user activity | AWS re:Post
Managing Aurora Serverless v2 DB clusters - Amazon Aurora
If your Aurora is publicly available, then this can cause it when people are trying to brute force it.
In my case such behaviour was caused by monitoring if DB port is open. Please remember, that with Serverless Pause enabled just checking if the port is open with tools like:
$ nc -z -v -w 3 auradb.eu-west-1.rds.amazonaws.com 5432
$ telnet auradb.eu-west-1.rds.amazonaws.com 5432
will cause the DB to resume from sleep. That is not even connecting to the DB, just checking the port is enough to trigger a resume. Such activity is not reported by database (maybe checking logging traces can help here) and CloudWatch monitoring can show no Database Connections.
Relevant content
- asked a year ago
- asked 4 years ago
- AWS OFFICIALUpdated 4 months ago
