- Newest
- Most votes
- Most comments
To check if AWS Direct Connect is under maintenance or has scheduled maintenance, you have a few options:
-
Monitor notifications: AWS sends maintenance notifications through email or the AWS Personal Health Dashboard. Regularly check these channels for any scheduled maintenance events.
-
Use Amazon CloudWatch: You can set up CloudWatch alarms to monitor the physical connection status of your Direct Connect connections. While this doesn't directly indicate maintenance, it can alert you to connection issues.
-
Implement CloudWatch Network Monitor: This tool provides active monitoring of your Direct Connect connections and can help you detect issues or maintenance events.
-
Check the AWS Direct Connect console: The console displays the current status of your connections, including any ongoing maintenance.
-
Monitor BGP status: Although CloudWatch doesn't directly monitor BGP status, you can check the BGP status on your on-premises router connected to the Direct Connect circuit. Consider logging this status to a log aggregator like CloudWatch Logs and setting up metric filters to monitor it.
For your specific use case with persistent database connections in a PHP application, you might consider implementing a connection health check in your application. This could involve periodically testing the connection and switching ATTR_PERSISTENT to false if issues are detected, rather than relying solely on maintenance notifications.
It's also worth noting that if you've configured your Direct Connect environment to be resilient, your traffic should automatically route through redundant connections during maintenance. Regular testing of this failover capability is recommended to ensure reliability during actual maintenance events or failures.
Sources
AWS Direct Connect maintenance - AWS Direct Connect
Operational excellence pillar - Hybrid Networking Lens
AWS Direct Connect BGP Status monitoring | AWS re:Post
Logging and monitoring in AWS Direct Connect - AWS Direct Connect
There is no CLI command that will tell you of DX is currently under maintenance. However, you can use a combination of CLI commands in your situation
aws directconnect describe-connections
If status is down, it means something is wrong like it could be under maintenance.
aws health describe-events --filter services=directconnect eventStatusCodes=open
aws health describe-event-details --event-arns 'arn:aws:health:123456'
Using the above commands, you could check if there maintenance scheduled.
I know these are CLI commands, you can however, find the correct code by checking AWS SDK for PHP. https://docs.aws.amazon.com/sdk-for-php/v3/developer-guide/welcome.html