Accessing Odoo Container Logs in CloudWatch
This guide explains how to access and monitor Odoo container logs in AWS CloudWatch for troubleshooting and monitoring purposes.
When to Check Logs
You may need to access CloudWatch logs in the following situations: - Troubleshooting application errors or crashes - Monitoring container restart processes - Investigating performance issues - Debugging integration problems - Checking startup sequences after deployments
Prerequisites
- Access to AWS Console with CloudWatch read permissions
- Knowledge of the specific log group for Odoo containers
Step-by-Step Process
1. Navigate to CloudWatch
- Open AWS Console: Navigate to AWS Console
- Find CloudWatch:
- Search for "CloudWatch" in the services search bar
- Click on "CloudWatch"
2. Access Log Groups
- Logs Section: In the CloudWatch console, click on "Logs" in the left sidebar
- Log Groups: Click on "Log groups"
- Find Odoo Logs: Look for the log group named
/ecs/odoo_self_hosted - Open Log Group: Click on
/ecs/odoo_self_hostedto view the log streams
3. View Log Streams
- Select Log Stream: Each ECS task generates its own log stream
- Log streams are typically named with the task ID and timestamp
- The most recent streams appear at the top (sorted by "Last Event Time")
- View Logs: Click on a log stream to view the detailed logs
- Navigate Logs: Use the scroll functionality or timestamp navigation to find specific events
4. Understanding Log Stream Names
Log stream names typically follow this pattern:
Where:
- OdooOnPrem/odoo-http/indicates the container and task definition
-[task-id]` is the unique identifier for the ECS task instance