Nginx를 통해 HHVM을 사용하고 싶습니다. 내가 여기에 언급 된 단계를 수행 한Nginx fastcgi가있는 HHVM이 제대로 작동하지 않습니다.
(우분투 12.04.2 LTS, PHP 5.3.10) :
server {
listen 80;
server_name demo1.dev
server_name_in_redirect off;
root /var/www/demo1;
location/{
index index.php;
try_files $uri $uri/ @handler;
expires 30d;
}
location @handler {
rewrite//index.php;
}
location ~ .php$ {
fastcgi_keep_conn on;
if (!-e $request_filename) { rewrite//index.php last; }
expires off;
fastcgi_pass 127.0.0.1:9000;
fastcgi_param PHP_VALUE "error_log=/var/report/PHP.error.log";
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
location ~* \.(js|css|png|jpg|jpeg|gif|ico)$ {
expires 1y;
log_not_found off;
}
}
나는이 :
http://www.hhvm.com/blog/1817/fastercgi-with-hhvm
이 내 Nginx의 설정이 모습입니다
function is_hhvm() {
return defined('HHVM_VERSION');
}
if (is_hhvm()) {
echo "HHVM is working\n";
} else {
echo "HHVM is not working\n";
}
무엇이 잘못 되었습니까? HHVM이 제대로 작동하는지 어떻게 알 수 있습니까?
UPDATE :의 출력 : ps auxf | grep hhvm
root 15164 0.0 0.0 9360 660 pts/0 S+ 13:55 0:00 \_ grep --color=auto hhvm
www-data 15142 4.2 6.3 576564 122484 ? Ss 13:54 0:01 /usr/bin/hhvm --config /etc/hhvm/server.hdf --user www-data --mode daemon
www-data 15154 7.0 6.3 580668 122636 ? Ss 13:54 0:01 /usr/bin/hhvm --config /etc/hhvm/server.hdf --user www-data --mode daemon -vServer.Type=fastcgi -vServer.Port=9000 -vPidFile=/var/run/hhvm/hhvm-fastcgi.pid
비슷한 문제가있는 것처럼 보였지만 nginx와는 아무런 관련이 없습니다. http://stackoverflow.com/questions/21036910/debugging-in-nginx-yields-1-line-and-infinite-frustration -how-to-debug-the-debu –