"Primary script Unknown" while Reading Response header from upstream - NGINX

Asked

Viewed 1,088 times

2

Hello, I am trying to run my Wordpress site on the Host that has this setting:

  • Ubuntu LTS 16.04, Nginx, Apache, Mysql, PHP, Webmin

While trying to enter the home page, the error that is displayed in the error log, is this below:

2018/05/03 02:35:22 [error] 3372#3372: *1 Fastcgi sent in stderr: "Primary script Unknown" while Reading Response header from upstream, client: 187.103.234.71, server: meusite.com, request: "GET / HTTP/1.1", upstream: "fastcgi://Unix:/run/php/php7.0-fpm.Sock:", host: "meusite.com"

Any idea what it might be? I started to venture now in the creation of my own server, then the errors started to appear and I need help to understand the root and try to solve.

Thank you!

  • If you are familiar with English (I am ruimzin) you have an answer here: https://serverfault.com/q/517190

  • @Don'tPanic I’ll take a look!

1 answer

-1

Your problem is this in fastcgi configuration. On Webmin >>> Go to Virtualmin >>> Select Domain >>> Services >> Server Configuration >> Website Options

There must be more than one option, besides the selected CGI. Select another option and Save.

THE SITE WILL NOT WORK (BUT CHECK, MAYBE IT IS THE CASE OF CHANGING ITS CONFIGURATION) In case your website doesn’t come back... Make the same way up and go back to CGI as it was. So your website will reconfigure the CGI SOCKET.


NGINX & APACHE is Web Server and Reverse Proxy

This is both can only be used if you set up on different ports.

For example:

APACHE= PORT:8080 NGINX= DOOR:80 If you use cache as Varsish, check port settings

However, using both is possible. Set up Nginx as an Apache Web Server and Reverse Proxy.

  • 1

    In fact, you can run Apache as webserver and NGINX as proxy, as is done in VESTACP, for example.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.