- Newest
- Most votes
- Most comments
If you're experiencing rapid growth in the v$archived_log for your Oracle RDS instance despite setting the retention time to 0, there are a few important points to consider:
-
Retention setting: Even if you've set the retention time to 0, RDS for Oracle will still generate archived redo logs as long as the backup retention period is greater than zero. By default, RDS retains backups, which includes these logs.
-
Backup retention: Check your RDS instance's backup retention period. If it's set to the default of 7 days, this could explain why you're seeing a large amount of archived logs. Consider reducing the backup retention period to the minimum of 1 day if possible, which may help reduce the storage consumed by backups and archived logs.
-
Storage usage: The query you're using is correct for checking the total size of archived logs. To get a more detailed view of how much space is being used over time, you could modify the query to group by date:
SELECT TRUNC(FIRST_TIME, 'DD') AS log_date, ROUND(SUM(BLOCKS * BLOCK_SIZE) / 1024 / 1024 / 1024, 2) AS archived_logs_gb FROM v$archived_log GROUP BY TRUNC(FIRST_TIME, 'DD') ORDER BY log_date;
-
Database activity: High amounts of database changes can lead to rapid growth in archived logs. Review your database activity and see if there are any operations that could be optimized to reduce the generation of redo logs.
-
Monitoring: Regularly monitor your storage usage through the RDS dashboard. You can also use AWS CloudWatch to set up alerts for storage metrics.
-
Storage allocation: Ensure that your RDS instance has sufficient allocated storage to accommodate the growth of archived logs. You might need to increase the allocated storage or implement a strategy to manage the growth more effectively.
Remember, while reducing retention time can help, it's crucial to maintain enough logs for your recovery and backup needs. Always ensure your backup strategy aligns with your business requirements and compliance needs.
Sources
Use best practices to manage RDS for Oracle storage | AWS re:Post
Retaining archived redo logs - Amazon Relational Database Service
RDS/SQL Server Instance Storage Continues to Fill Even After Shrinking tempdb | AWS re:Post
Relevant content
- asked 10 months ago
- asked 8 months ago
- asked 3 years ago
