首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >hhvm-fastcgi + nginx如何在浏览器中显示致命错误

hhvm-fastcgi + nginx如何在浏览器中显示致命错误
EN

Stack Overflow用户
提问于 2014-04-15 22:37:44
回答 1查看 3.9K关注 0票数 18

我一直在尝试HHVM配置文件,但我还不能让它向浏览器输出任何致命的错误。它显示E_NOTICE和E_WARNING,但是当发生任何E_ERROR时,它将页面留空,并且错误只出现在HHVM日志文件中。

有没有办法让它在浏览器中显示出来?

我的HHVM配置文件如下:

代码语言:javascript
复制
PidFile = /var/run/hhvm/pid

Log {
  Level = Warning
  AlwaysLogUnhandledExceptions = true
  RuntimeErrorReportingLevel = 8191
  UseLogFile = true
  UseSyslog = false
  File = /var/log/hhvm/error.log
  InjectedStackTrace = false
  NativeStackTrace = false
  Access {
    * {
      File = /var/log/hhvm/access.log
      Format = %h %l %u % t \"%r\" %>s %b
    }
  }
}

ErrorHandling {
  CallUserHandlerOnFatals = true
  NoInfiniteLoopDetection = false
  NoInfiniteRecursionDetection = false
  ThrowBadTypeExceptions = false
  ThrowNotices = false
  NoticeFrequency = 1    # 1 out of these many notices to log
  WarningFrequency = 1   # 1 out of these many warnings to log
  AssertActive = false
  AssertWarning = false
}

Debug {
  FullBacktrace = false
  ServerStackTrace = false
  ServerErrorMessage = false
  TranslateSource = false

  RecordInput = false
  ClearInputOnSuccess = true

  ProfilerOutputDir = /tmp

  CoreDumpReport = true
  CoreDumpReportDirectory = /tmp
}

Http {
  DefaultTimeout = 30 # in seconds
  SlowQueryThreshold = 5000 # in ms, log slow HTTP requests as errors
}

Mail {
  SendmailPath = sendmail -t -i
  ForceExtraParameters =
}

Preg {
 BacktraceLimit = 100000
 RecursionLimit = 100000
}

Repo {
  Central {
    Path = /var/log/hhvm/.hhvm.hhbc
  }
}

Eval {
  Jit = true
}

MySQL {
  TypedResults = false
  ReadOnly = false
  ConnectTimeout = 2000      # in ms
  ReadTimeout = 2000         # in ms
  SlowQueryThreshold = 2000  # in ms, log slow queries as errors
  KillOnTimeout = false
}

Nginx:

代码语言:javascript
复制
location ~ \.php$ {
    fastcgi_keep_conn on;

    fastcgi_buffers 8 16k;
    fastcgi_buffer_size 32k;
    fastcgi_read_timeout 900;
    fastcgi_send_timeout 900;
    fastcgi_intercept_errors off;

    fastcgi_pass   127.0.0.1:9000;

    fastcgi_index  index.php;
    fastcgi_param  SCRIPT_FILENAME  $document_root$fastcgi_script_name;
    include        fastcgi_params;
}
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/23086903

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档