This article explains how to check the
access.log and related logs to troubleshoot 503 and 500 errors, which can be caused by traffic or insufficient server resources. Viewing the
access.log and related logs can provide information on what may be causing problems related to Magento Commerce Cloud.
Affected products and versions
- Magento Commerce Cloud, all supported versions.
How to check the access.log
To view logs for these server errors, check the
access.log on the web server, e.g., <ip address> <timestamp> <request uri> <response code> <referer url>
To check related logs:
- Run the following command in the CLI if it is on the current day (for Pro). Or up to a certain point in the past (for Starter), since the duration of the logs' coverage is limited, and log rotation is not available:
grep -r "\" [50[0-9]" /path/to/access.log
If the error has occurred in the past run the following command in the CLI (Pro only):
zgrep "\" 50[0-9]" /path/to/access.log.<rotation ID>.gz
- Then check the
error.logor the equivalent rotated log (logs that are automatically rotated and compressed when they reach a certain file size) for the same timestamp to locate the potential error and see what might have been occurring to have caused it.
Note: To check the
error.logrun the above commands in the CLI but replace