New answers tagged

0

I had precisely the same problem as ide and spent far longer trying to solve this than I had hoped. Since this is the only post or article I was able to find that helped me to adequately solve the issue, I wanted to add my solution to the mix. My configuration: Ubuntu 14.04 Apache 2.4.20 PHP-FPM 5.5.9-1ubuntu4.17 (fpm-fcgi) (built: May 19 2016 19:08:26) ...


0

I faced the problem today and after searching I eventually figured it out. Go to your Domain, i.e. open in a web browser: http://server_domain_name_or_IP/ On that page NGINX will list EDIT the File listed there In my case it is /etc/nginx/nginx.conf.


0

This sounds like a permissions issue to me, likely around groups. I go into detail in this tutorial, but the gist is below First the script I use to reset permissions chown -R tim:www-data * find /var/www/wordpress -type d -exec chmod 755 {} \; find /var/www/wordpress -type f -exec chmod 644 {} \; find /var/www/wordpress/wp-content/uploads -type f -exec ...


2

As /blog is the first component of the URI, you need to remove it from the root. Use root /path/to/my when inside location ^~ /blog. See this document for details. Also, your .php location is invalid syntax. You can use something like this: location ^~ /blog { root /path/to/my; index index.php; try_files $uri $uri/ /blog/index.php; ...


0

First in check if you have set the correct listen address in your www.conf file for PHP-FPM (FastCGI Process Manager). So open www.conf file (location: /etc/php5/fpm/pool.d/www.conf) and it should see somthing like this: Start a new pool named 'www'. [www] ;prefix = /path/to/pools/$pool user = www-data group = www-data listen = 127.0.0.1:8080 ; Set ...


0

Your home directory is protected from reading by other users. And starting nginx as root is a REALY bad idea. If you realy need your project to be located in your home directory try to start nginx and php-fpm as your user you login as. don't forget to chown all nginx service directories (/var/run/nginx and so on)


0

As far as I can see from your request, you try to get /web/API/v1/get/Common/GetActivities, which is not a real folder. You might do location /web/API/v1/get/Common/GetActivities with root /home/myname/public_html/domainname/public/projectname/web/API or change your request path on /web/API/index.php


0

There is a section in your site configuration for php. You should just need to simply add an access_log directive within that section location ~ .php$ { fastcgi_split_path_info ^(.+?\.php)(|/.*)$; include fastcgi_params; #NOTE: You should have "cgi.fix_pathinfo = 0;" in php.ini fastcgi_param PATH_TRANSLATED ...


2

Remove the enablereuse=on option on your Proxy line, so that it reads <Proxy fcgi://mywebsite/ retry=0> That solved the " Error dispatching request to : , referer... " problem for me.


0

You may need to specify a "From:" header in the sendmail command. Opendkim only signs Mails with an aligned "From:" header.


0

In addition to the timeout, set enablereuse=off. I found when it was on some requests to long running scripts would work correctly and others would be killed early.


0

As it turns out, when I copied over /var/lib/mysql from my old system, the permissions weren't corrected, resulting in nginx not having read access to the directory containing the socket file for MariaDB. The solution was to update the permissions on /var/lib/mysql so nginx had access.


0

If you set up PHP-FPM with mod_proxy_fcgi, which is newly available in Apache 2.4 for just this type of use case, you put your html and php files and all other web content files in your document root just like any other website. The Apache wiki entry for PHP-FPM has some good guidance to help you get up and running with the right configuration.


0

mod_fastcgi is a memory hog and generally difficult to set up. You should maybe try to set this up with mod_proxy_fcgi, which is newly available in Apache 2.4 for just this type of use case. The Apache wiki entry for PHP-FPM has some good guidance to get started. The mod_proxy_fcgi documentation also includes specific examples for setting up PHP-FPM and the ...


2

You have a property that is expecting a path, but is provided a boolean value, e.g. access_log on; access_log is expecting a path, but it is provided a boolean value on. You can confirm this by attentively reading the error: nginx: [emerg] open() "/usr/share/nginx/on" failed (13: Permission denied) Notice the on relative to your nginx base path.


0

Make sure the user running php has the sudo privileges to reload php5-fpm, then: shell_exec("nohup sh -c 'sleep 1; sudo reload php5-fpm' > /dev/null 2>&1 &");


0

Given the lack of information in the question, there is some guessing going on here. Assuming Apache 2.4 install from Ubuntu repository where standard MPM's are included with the install, it would appear that you just need to "switch" from prefork to worker. NOTE: You can ONLY start Apache with a single MPM selected, i.e. you MUST "dismod" the current MPM ...



Top 50 recent answers are included