Comments on: How to deploy a LEMP Stack with PHP-7.1 on CentOS 7 https://linuxhostsupport.com/blog/how-to-deploy-a-lemp-stack-with-php-7-1-on-centos-7/ Linux Tutorials and Guides Sun, 02 Aug 2020 16:49:56 +0000 hourly 1 https://wordpress.org/?v=6.6.1 By: admin https://linuxhostsupport.com/blog/how-to-deploy-a-lemp-stack-with-php-7-1-on-centos-7/#comment-94 Thu, 06 Sep 2018 04:03:17 +0000 https://linuxhostsupport.com/blog/?p=264#comment-94 In reply to vipul.

Please follow the steps carefully, you should be able to run PHP files.

]]>
By: vipul https://linuxhostsupport.com/blog/how-to-deploy-a-lemp-stack-with-php-7-1-on-centos-7/#comment-93 Tue, 04 Sep 2018 19:36:46 +0000 https://linuxhostsupport.com/blog/?p=264#comment-93 Hi

This is not working.

Can you tell what chown to php.sock

As when I load site page it load only html page. PHP code is not loading.

]]>
By: dietoo https://linuxhostsupport.com/blog/how-to-deploy-a-lemp-stack-with-php-7-1-on-centos-7/#comment-82 Tue, 24 Jul 2018 20:16:31 +0000 https://linuxhostsupport.com/blog/?p=264#comment-82 Thanks for the post!,
I was getting an error in the last step 4 (before restart php), then it works for me:

Change listen = /run/php/php7.1-fpm.sock
by listen = /var/run/php71.sock

I also did it :

– Uncomment and change socket owner
listen.owner = nginx
listen.group = nginx
listen.mode = 0660

]]>
By: Miles https://linuxhostsupport.com/blog/how-to-deploy-a-lemp-stack-with-php-7-1-on-centos-7/#comment-74 Sat, 07 Jul 2018 06:08:18 +0000 https://linuxhostsupport.com/blog/?p=264#comment-74 In reply to Thiago.

chown nginx. php -R didnt work for me but chown -R nginx:nginx php did.
Thanks Thiago

]]>
By: Thiago https://linuxhostsupport.com/blog/how-to-deploy-a-lemp-stack-with-php-7-1-on-centos-7/#comment-64 Sun, 06 May 2018 15:10:54 +0000 https://linuxhostsupport.com/blog/?p=264#comment-64 Excellent post, so far the best! Congratulations! Hugs from all over Brazil!

What do you think of creating Part 2 to include PHPMyAdmin?

]]>
By: Thiago https://linuxhostsupport.com/blog/how-to-deploy-a-lemp-stack-with-php-7-1-on-centos-7/#comment-63 Sun, 06 May 2018 13:52:42 +0000 https://linuxhostsupport.com/blog/?p=264#comment-63 Problem solved!

I created the php directory inside run [/ run / php /]. Then I created [php7.1-fpm.sock] inside php. By accessing the / run / executed [chown nginx. php -R].

Note that if you do not execute chown, the error below is reported. Then do everything above, which corrects the fault.

2018/05/06 09:46:44 [crit] 21007 # 0: * 35 connect () to unix: /run/php/php7.1-fpm.sock failed (13: Permission denied) while connecting to upstream, client : MY_IP, server: MY_DOMAIN, request: “GET /info.php HTTP / 1.1”, upstream: “fastcgi: // unix: /run/php/php7.1-fpm.sock:”, host: “MY_DOMAIN”

==> /var/log/nginx/access.log <==
My_IP – – [06 / May / 2018: 09: 46: 44 -0400] "GET /info.php HTTP / 1.1" 502 575 "-" "Mozilla / 5.0 (Windows NT 6.3; Win64; x64) AppleWebKit / 537.36 KHTML, like Gecko) Chrome / 66.0.3359.139 Safari / 537.36 "" – "

]]>
By: Thiago https://linuxhostsupport.com/blog/how-to-deploy-a-lemp-stack-with-php-7-1-on-centos-7/#comment-62 Sun, 06 May 2018 13:32:42 +0000 https://linuxhostsupport.com/blog/?p=264#comment-62 When you run the [LISTEN, USER AND GROUP] step on a CentOS 7.4 server, the following message is displayed:

ERROR: unable to bind listening socket for address ‘/run/php/php7.1-fpm.sock’: No such file or directory

]]>
By: Chiranjeev https://linuxhostsupport.com/blog/how-to-deploy-a-lemp-stack-with-php-7-1-on-centos-7/#comment-37 Sat, 13 Jan 2018 12:31:34 +0000 https://linuxhostsupport.com/blog/?p=264#comment-37 Check the ‘fastcgi_pass’ setting in your nginx server blocks, and change it to:

fastcgi_pass unix:/run/php/php7.1-fpm.sock;

]]>