小编Man*_*ano的帖子

如何查看 Nginx 编译时使用了哪些标志?

如何检查已将哪些模块添加到 nginx 安装中?

nginx

245
推荐指数
3
解决办法
16万
查看次数

nginx 上的未知指令“fastcgi_pass”

我在配置服务器和其他东西方面的​​经验很少,所以我完全迷失了。

我试图在 nginx 安装中添加 php 支持,但是当把它放在 nginx.conf 中时。

location ~ \.php$ {
        root           html;
        fastcgi_pass   127.0.0.1:9000;
        fastcgi_index  index.php;
        fastcgi_param  SCRIPT_FILENAME  /scripts$fastcgi_script_name;
        include        fastcgi_params;
    }
Run Code Online (Sandbox Code Playgroud)

并且我尝试重新启动,出现此错误消息

 [emerg]: unknown directive "fastcgi_pass" in /opt/nginx/conf/nginx.conf:67
Run Code Online (Sandbox Code Playgroud)

有什么线索吗?

提前致谢

PD:

nginx -V 输出nginx版本:nginx/0.7.67 build by gcc 4.1.2 20080704 (Red Hat 4.1.2-48) --prefix=/opt/nginx --without-http_fastcgi_module --without-http_memcached_module --without- mail_pop3_module --without-mail_imap_module --without-mail_smtp_module --with-http_flv_module --add-module=../nginx_mod_h264_streaming-2.2.7 --without-http-cache

nginx php5

2
推荐指数
1
解决办法
8432
查看次数

标签 统计

nginx ×2

php5 ×1