【问题标题】:Where is the fast-cgi configuration file for nginx, php.ini conf file located?nginx的fast-cgi配置文件,php.ini conf文件在哪里?
【发布时间】:2012-04-07 16:05:38
【问题描述】:

我收到 504 bad gateway nginx 错误。我已经阅读了很多关于这个问题和所有可能的原因。我也读过this

我在我的服务器上找不到配置文件。

我试过sudo nano /usr/local/nginx/conf/fastcgi.conf,但是,这不是正确的位置。

我也试过sudo nano /usr/local/nginx/conf/nginx.conf,但没有成功。

这是nginx.conf的输出:

user www-data www-data;
worker_processes  4;
events {
    worker_connections  1024;
}
http {
    include       mime.types;
    default_type  application/octet-stream;
    sendfile        on;
    tcp_nopush      on;
    tcp_nodelay     off;
    keepalive_timeout  5;
    gzip  on;
    gzip_comp_level 2;
    gzip_proxied any;
    gzip_types      text/plain text/css application/x-javascript text/xml application/xml $
    include /usr/local/nginx/sites-enabled/*;
}

我想更改fastcgi_read_timeout 和其他设置,例如fastcgi_send_timeout

我还读到它可能也在php.ini,但是我不确定它在哪里。

非常感谢!

【问题讨论】:

    标签: nginx fastcgi


    【解决方案1】:

    将它们添加到 nginx.conf 文件中。

    工作方式是这些指令有默认值。如果没有指令,则使用默认值。要覆盖默认值,您需要专门添加指令。

    【讨论】:

      猜你喜欢
      • 2017-11-19
      • 1970-01-01
      • 1970-01-01
      • 2016-10-31
      • 2017-10-19
      • 2015-05-25
      • 1970-01-01
      • 1970-01-01
      • 2019-07-01
      相关资源
      最近更新 更多