White death screen in yii2



  • Hello, everyone! I think my app went crazy. Frequently, on certain pages of my application, a white screen, instead of a page, the reference code is completely empty, and the white screen is sometimes replaced by 502 bad gateways, has included all errors in yii, index.php

    error_reporting(-1);
    ini_set('display_errors', true);
    ini_set('display_startup_errors', true);
    

    The white screen goes missing and the Notice errors are made, no fatal errors. But the weirdest thing about rebooting the server is getting normal, the white screen stops showing up. When I'm trying to get on a white screen page, clicking on the reference, there's nothing on the page, pages like it's up, there's a text-wraper (I), a browser at some point says the page has not been downloaded. I don't even know which side to dig and what to do, except to overload the server... maybe someone's been dealing with something like that? Which way?

    nginx/1.6.3
    PHP 5.5.30
    


  • Turn on the php logging.

    In the wound, one can do the following:

    ini_set("log_errors", 1);
    ini_set("error_log", "path/to/php-error.log");
    

    Look at the logs that write the framework, in the folder runtime/logs/, study the logs, correct the mistakes, and the ecran of death will fall.

    P.S.: In Yii2 you're gonna get debbager-- https://github.com/yiisoft/yii2-debug but don't use it for sale.




Suggested Topics

  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2