Oracle Data Guard keeps a standby database in sync for high availability and disaster recovery, but running switchover and failover by hand on Amazon EC2 is slow and error-prone. This post shows how to automate both with AWS Step Functions and AWS Lambda, running validated pre-checks, the role transition, post-checks, and RTO/RPO tracking end to end.