[root@yaho nginx]# curl localhost/i.php

<html>

<head><title>502 Bad Gateway</title></head>

<body bgcolor="white">

<center><h1>502 Bad Gateway</h1></center>

<hr><center>nginx/1.4.4</center>

</body>

</html>

原因:问题出在php-fpm.conf  配置文件里,把里面的 listen =/tmp/php-abc.sock和 nginx.conf里  fastcgi_pass unix:/tmp/php-abc.sock;不一致,修改一致解决问题.