1

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 4

2

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/
1

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

6
  • But I'm not finding php error log file under magento 2 under var/log dir.
    – NoOn
    Jul 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
  • And how about ubuntu log file for php errors?
    – NoOn
    Jul 20, 2022 at 8:27
  • 1
    Try this askubuntu.com/questions/14763/… Jul 20, 2022 at 8:56
  • 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
0

It is version dependent :

  1. /var/log/nginx/error.log Or
  2. /usr/local/var/log/nginx/* Or
  3. /usr/local/nginx/logs/*
1
0

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.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.