我正在使用 php-fpm。在 5.3.2 中,当我在访问日志中打开 phpinfo 页面时,我得到:
ip - - [26/Aug/2010:16:35:32 +0400] "GET /phpinfo.php HTTP/1.1" 200 13322 "-" "Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.5) Gecko/20091102 Firefox/3.5.5"
但在 5.3.3 中我得到了:
ip - - [26/Aug/2010:16:30:30 +0400] "GET /phpinfo.php HTTP/1.1" 200 11891 "-" "Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.5) Gecko/20091102 Firefox/3.5.5"
ip - - [26/Aug/2010:16:30:30 +0400] "GET /phpinfo.php?=PHPE9568F34-D428-11d2-A769-00AA001ACF42 HTTP/1.1" 200 2536 "http://site.com/phpinfo.php" "Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.5) Gecko/20091102 Firefox/3.5.5"
ip - - [26/Aug/2010:16:30:30 +0400] "GET /phpinfo.php?=SUHO8567F54-D428-14d2-A769-00DA302A5F18 HTTP/1.1" 200 2825 "http://site.com/phpinfo.php" "Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.5) Gecko/20091102 Firefox/3.5.5"
ip - - [26/Aug/2010:16:30:30 +0400] "GET /phpinfo.php?=PHPE9568F35-D428-11d2-A769-00AA001ACF42 HTTP/1.1" 200 2158 "http://site.com/phpinfo.php" "Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.5) Gecko/20091102 Firefox/3.5.5"
为什么有 4 行而不是 1 行?“?=PHPE...”是什么意思?是 PHP 会话吗?
我的 php5.3.3 fpm 配置:
[global]
pid = /var/run/php5-fpm.pid
error_log = /var/log/php5-fpm.log
log_level = notice
[pool_0]
listen = 127.0.0.1:9000
listen.backlog = -1
listen.allowed_clients = 127.0.0.1
user = www-data
group = www-data
pm = dynamic
pm.max_children = 50
pm.min_spare_servers = 5
pm.max_spare_servers = 35
pm.max_requests = 500
pm.status_path = /pool_0/status
rlimit_files = 1024
rlimit_core = 0
catch_workers_output = yes
php_admin_flag[register_globals] = true
php_admin_value[error_reporting] = E_ALL & ~E_DEPRECATED
php_admin_value[max_execution_time] = 15
php_admin_flag[short_open_tag] = true
php_admin_flag[display_errors] = false
答案1
expose_php
启用此设置后,phpinfo
输出将包含 3 张徽标图像。这些图像是使用您在日志文件中看到的三个额外请求加载的。