A development team runs monthly resource-intensive tests on its general purpose Amazon RDS for MySQL DB instance with Performance Insights enabled. The testing lasts for 48 hours once a month and is the only process that uses the database. The team wants to reduce the cost of running the tests without reducing the compute and memory attributes of the DB instance. Which solution meets these requirements MOST cost-effectively?
A. Stop the DB instance when tests are completed. Restart the DB instance when required.
B. Use an Auto Scaling policy with the DB instance to automatically scale when tests are completed.
C. Create a snapshot when tests are completed. Terminate the DB instance and restore the snapshot when required.
D. Modify the DB instance to a low-capacity instance when tests are completed. Modify the DB instance again when required.
C
技巧:排除明显错误选项,在没有明显错误的选项中选择最合理的选项。
一个开发团队在其通用型 Amazon RDS for MySQL 数据库实例上运行每月一次的资源密集型测试,且已启用 Performance Insights。这些测试每次持续 48 小时,是唯一使用该数据库的过程。团队希望在不降低数据库实例的计算和内存属性的情况下,降低运行这些测试的成本。
A. 不正确。在测试完成后停止 DB 实例。在需要时重新启动 DB 实例。Amazon RDS 支持停止和启动数据库实例,停止实例后将不再产生计算费用,用户只需要支付储费用。暂停实例,间歇性地停止数据库实例,来进行临时测试或执行日常开发活动,但是最长可以连续停止 7 天。
B. 不正确。使用 Auto Scaling 策略与 DB 实例结合,在测试完成后自动扩展。Amazon RDS 本身不直接支持 Auto Scaling。
C. 正确。在测试完成后创建快照。终止 DB 实例并在需要时从快照恢复。创建快照并终止实例确实可以节省成本,终止实例后将不再产生计算费用,只需要快照费用。但是快照主要用于数据备份和恢复,而不是作为常规的成本节省策略,从快照恢复实例是一个耗时的过程。
D. 不正确。在测试完成后将 DB 实例修改为低容量实例。在需要时再次修改 DB 实例。Amazon RDS 的实例类型和容量不能随时增加或者减少而不影响数据库的可用性。修改实例类型通常需要创建一个新的实例或进行某种形式的迁移,这可能导致停机时间或数据不一致。修改实例可能会变更 RDS 实例的计算和内存属性,而且修改过程本身可能带来额外成本和复杂性。