How to see error log file for php 7.4 in Magento 2 project which is working ubuntu. or how to set new log file location.
4 Answers
The following logs have a common location for all Magento projects:
Deployment log: var/log/cloud.log
Last deployment error log: var/log/cloud.error.log
Debug log: var/log/debug.log
Exception log: var/log/exception.log
System log: var/log/system.log
Support log: var/log/support_report.log
Reports: var/report/
All errors (and other notices) are logged in files under var/log
in the root of your Magento project. There you can find your error logs
-
But I'm not finding php error log file under magento 2 under var/log dir.– NoOnJul 20, 2022 at 7:23
-
There are no php error log files in Magento. All the log files that exist in Magento are described by @divyarajsinh-barad in his answer. Jul 20, 2022 at 8:23
-
-
1
-
1
sudo tail /var/log/nginx/error.log -n 200
will give you the last 200 logs. Change the number to get more or less. Jul 20, 2022 at 9:01
It is version dependent :
- /var/log/nginx/error.log Or
- /usr/local/var/log/nginx/* Or
- /usr/local/nginx/logs/*
You can also check your nginx.conf
"run nginx -t" command to locate your nginx.conf.
In your ngingx.conf file :
error_log /usr/local/var/log/nginx/error.log;
error_log /usr/local/var/log/nginx/error.log notice;
error_log /usr/local/var/log/nginx/error.log info;
here you can see the logs.