Some Drupal Nginx Help Please

We encourage users to post events happening in the community to the community events group on https://www.drupal.org.
Chad_Dupuis's picture

Hello,

I am setting up a new server to move some of my drupal sites to. I'm trying to switch everything over to nginx, php-fpm, etc. I have everything setup and have used perusio's scripts extensively. I can see the php-fpm status pages, I can reach the domain - in this case http://contemplativechristianliving.com/ - but I cannot get any actual drupal pages to show up... What I see in the error logs are endless entries such as:

2011/12/23 19:23:47 [crit] 3199#0: *198 connect() to unix:/var/run/php-fpm.sock failed (2: No such file or directory) while connecting to upstream, client: ::ffff:66.249.71.229, server: contemplativechristianliving.com, request: "GET /bible/1/GEN/57 HTTP/1.1", upstream: "fastcgi://unix:/var/run/php-fpm.sock:", host: "contemplativechristianliving.com"

php-fpm.sock exists and I've just been going in circles trying to figure out where else I should look to get this straightened out. I'm fairly certain it's a nginx configuration issue, but I cannot figure it out. Any ideas would be much appreciated..

Thanks,
-Chad.

Comments

A little update that may be

Chad_Dupuis's picture

A little update that may be helpful... When I try to view index.php I get the site offline page from drupal and in the access log I see the following:

::ffff:76.123.113.235 - - [23/Dec/2011:20:38:16 -0500] "GET /index.php HTTP/1.1"
503 1021 "-" "Mozilla/5.0 (X11; Linux x86_64; rv:8.0) Gecko/20100101 Firefox/8.
0"

I reset the error logs and now there is nothing in it - so the php-fpm errors from above are probably not happening anymore. That said, I'm still not seeing my website. The database and settings seem fine, I can login from the command line...

If I put a straight html file in the webservers directory it shows up - as does a phpinfo file, but with drupal's index.php I get the error above - oddly I still get the same error even if I turn off mysql - so to me it seems like something in the nginx configs...

Your Drupal installation is not happy

oadaeh's picture

This probably does not have anything to do with Nginx.

Start by trying to clear your caches by going to ?q=admin/config/development/performance and clicking the "Clear all caches" button. You may need to login, first. You can do that here: ?q=user.

If that doesn't fix it, try disabling Clean URLs, here: ?q=admin/config/search/clean-urls.

If that doesn't do it, start going through the troubleshooting tips, starting on this page: http://drupal.org/Troubleshooting-FAQ.

You are correct oadaeh, I had

Chad_Dupuis's picture

You are correct oadaeh, I had some problems with mysql and php that were not helping. Now, however, I have things up and running and can get to the front page but I am getting lots of redirection errors which is an nginx issue.... I have the following lines from perusio's scripts which seem to be doing something incorrect (or, more likely, I have them setup incorrectly):

Right now http://contemplativechristianliving.com/index.php will pull up the front page but all other pages end up with redirect errors
http://www.contemplativechristianliving.com redirects to an IANA example domains page?

## Return (no rewrite) server block.
server {
    ## This is to avoid the spurious if for sub-domain name
    ## "rewriting".
    listen [::]:80;
    server_name www.contemplativechristianliving.com;
    return 301 $scheme://contemplativechristianliving.com$request_uri;

} # server domain return.

## HTTP server.
server {
    listen [::]:80;
    server_name contemplativechristianliving.com;
    limit_conn arbeit 32;
...

You have to replace

perusio's picture

the example.com domain. Also what type of socket are you using for php-fpm. TCP or UNIX domain?

Right now your site is served by Apache:

HTTP/1.1 200 OK
Date: Sat, 24 Dec 2011 23:06:19 GMT
Server: Apache/2.2.11 (Ubuntu) PHP/5.2.13-0.dotdeb.1 with Suhosin-Patch mod_ssl/2.2.11 OpenSSL/0.9.8g
X-Powered-By: PHP/5.2.13-0.dotdeb.1
Set-Cookie: SESS9f9dd69bfd2d172434d50fc58ea3a1f7=4c00d65abb0fcaa03bf1c1c93003a84d; expires=Tue, 17-Jan-2012 02:39:39 GMT; path=/; domain=.contemplativechristianliving.com
Expires: Sun, 19 Nov 1978 05:00:00 GMT
Last-Modified: Sat, 24 Dec 2011 23:06:19 GMT
Cache-Control: store, no-cache, must-revalidate
Cache-Control: post-check=0, pre-check=0
Vary: Accept-Encoding
Content-Type: text/html; charset=utf-8
Connection: keep-alive

No nginx, No pressflow either. You're exposing a lot if info about your setup.

I'm using unix sockets for

Chad_Dupuis's picture

I'm using unix sockets for php-fpm -
fpm-status has:
pool: www
process manager: dynamic
accepted conn: 757
listen queue len: 0
max listen queue len: -1
idle processes: 5
active processes: 0
total processes: 5
max children reached: 1

and ping - gives pong

Are you using

perusio's picture

global redirect? If so that will give a redirection loop due to the deslash setting. You have to remove that setting.

With drush do:

drush vset deslash 0

Also you won't get any caching, since you're sending the session cookie back and forth. To disable that either use pressflow or install no_anon.

Thank you... the site does

Chad_Dupuis's picture

Thank you...

the site does have global redirect - but I had already installed your nginx deslash module for d6 via drush per your instructions.... I did just run the drush command, restarted everything and still the same redirects. Any other ideas??

As for caching, we are fine with this on this site, it will upgrade to pressflow soon, this is really just a test for a couple more important sites that do need caching and run pressflow, etc.

You have to enable the debug log

perusio's picture

and see how the Nginx processes the request. Follow the instructions. Paste the result here if you have difficulties interpreting the log.

Alerts from the nginx general

Chad_Dupuis's picture

Alerts from the nginx general error log:

2011/12/24 22:42:37 [alert] 2642#0: epoll_ctl(1, 0) failed (1: Operation not permitted)
2011/12/24 22:42:37 [alert] 2642#0: failed to register channel handler while initializing push module worker (1: Operation not permitted)
2011/12/24 22:42:37 [alert] 2641#0: epoll_ctl(1, 0) failed (1: Operation not permitted)
2011/12/24 22:42:37 [alert] 2641#0: failed to register channel handler while initializing push module worker (1: Operation not permitted)
2011/12/24 22:42:37 [alert] 2636#0: cache manager process 2641 exited with fatal code 2 and cannot be respawned

A couple criticals from the site specific error log:

2011/12/24 16:09:40 [crit] 1839#0: *3 connect() to unix:/var/run/php-yyhmsgfpm2fpm.sock failed (2: No such file or directory) while connecting to upstream, client: 76.123.113.235, server: contemplativechristianliving.com, request: "GET / HTTP/1.1", upstream: "fastcgi://unix:/var/run/php-yyhmsgfpm2fpm.sock:", host: "contemplativechristianliving.com"
2011/12/24 16:12:35 [crit] 1839#0: *68 connect() to unix:/var/run/php-yyhmsgfpm2fpm.sock failed (2: No such file or directory) while connecting to upstream, client: 204.62.14.110, server: contemplativechristianliving.com, request: "GET /index.php HTTP/1.0", upstream: "fastcgi://unix:/var/run/php-yyhmsgfpm2fpm.sock:", host: "contemplativechristianliving.com"

I noticed on another post that you helped on that someone was getting similar behavior with apc enabled ( http://nginx.2469901.n2.nabble.com/After-upgrading-nginx-from-0-8-54-to-... )
I did install the php-acp package from Brian Mercer's repository but that's 3.1.9 so it shouldn't be a problem...

Here's a general snapshot of the log - very little of these means anything to me:

2011/12/24 22:55:05 [debug] 2660#0: 46 post access phase: 12
2011/12/24 22:55:05 [debug] 2660#0: *46 try files phase: 13
2011/12/24 22:55:05 [debug] 2660#0: *46 upload-progress: ngx_http_uploadprogress
_content_handler
2011/12/24 22:55:05 [debug] 2660#0: *46 posix_memalign: 0000000002463150:4096 @1
6
2011/12/24 22:55:05 [debug] 2660#0: *46 http init upstream, client timer: 0
2011/12/24 22:55:05 [debug] 2660#0: *46 epoll add event: fd:21 op:3 ev:80000005
2011/12/24 22:55:05 [debug] 2660#0: *46 http script var: "contemplativechristian
living.com"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script var: "/bible/7/PS"
2011/12/24 22:55:05 [debug] 2660#0: *46 http cache key: "contemplativechristianl
iving.com/bible/7/PS"
2011/12/24 22:55:05 [debug] 2660#0: *46 http map started
2011/12/24 22:55:05 [debug] 2660#0: *46 http map: "" "0"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script var: "0"
2011/12/24 22:55:05 [debug] 2660#0: *46 add cleanup: 0000000002463800
2011/12/24 22:55:05 [debug] 2660#0: *46 http file cache exists: -5 e:0
2011/12/24 22:55:05 [debug] 2660#0: *46 cache file: "/var/cache/nginx/microcache
/2/34/e308c383aa01bf94c75a7c7d4ca50342"
2011/12/24 22:55:05 [debug] 2660#0: *46 add cleanup: 0000000002463860
2011/12/24 22:55:05 [debug] 2660#0: *46 http upstream cache: -5
2011/12/24 22:55:05 [debug] 2660#0: *46 http script copy: "QUERY_STRING"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script var: "q=/bible/7/PS&"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "QUERY_STRING: q=/bible/7
/PS&"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script copy: "REQUEST_METHOD"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script var: "GET"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "REQUEST_METHOD: GET"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script copy: "CONTENT_TYPE"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "CONTENT_TYPE: "
2011/12/24 22:55:05 [debug] 2660#0: *46 http script copy: "CONTENT_LENGTH"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "CONTENT_LENGTH: "
2011/12/24 22:55:05 [debug] 2660#0: *46 http script copy: "SCRIPT_NAME"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script var: "/index.php"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "SCRIPT_NAME: /index.php"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script copy: "REQUEST_URI"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script var: "/bible/7/PS"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "REQUEST_URI: /bible/7/PS
"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script copy: "DOCUMENT_URI"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script var: "/index.php"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "DOCUMENT_URI: /index.php
"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script copy: "DOCUMENT_ROOT"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script var: "/var/www/sites/contemp
lativechristianliving.com"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "DOCUMENT_ROOT: /var/www/
sites/contemplativechristianliving.com"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script copy: "SERVER_PROTOCOL"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script var: "HTTP/1.1"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "SERVER_PROTOCOL: HTTP/1.
1"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script copy: "GATEWAY_INTERFACE"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script copy: "CGI/1.1"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "GATEWAY_INTERFACE: CGI/1
.1"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script copy: "SERVER_SOFTWARE"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script copy: "nginx/"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script var: "1.0.11"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "SERVER_SOFTWARE: nginx/1
.0.11"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script copy: "REMOTE_ADDR"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script var: "::ffff:157.55.16.231"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "REMOTE_ADDR: ::ffff:157.
55.16.231"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script copy: "REMOTE_PORT"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script var: "32574"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "REMOTE_PORT: 32574"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script copy: "SERVER_ADDR"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script var: "::ffff:204.62.14.110"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "SERVER_ADDR: ::ffff:204.
62.14.110"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script copy: "SERVER_PORT"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script var: "80"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "SERVER_PORT: 80"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script copy: "SERVER_NAME"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script var: "contemplativechristian
living.com"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "SERVER_NAME: contemplati
vechristianliving.com"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script copy: "SCRIPT_FILENAME"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script var: "/var/www/sites/contemp
lativechristianliving.com"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script var: "/index.php"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "SCRIPT_FILENAME: /var/ww
w/sites/contemplativechristianliving.com/index.php"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script copy: "REDIRECT_STATUS"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script copy: "200"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "REDIRECT_STATUS: 200"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "HTTP_CACHE_CONTROL: no-c
ache"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "HTTP_CONNECTION: Keep-Al
ive"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "HTTP_PRAGMA: no-cache"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "HTTP_ACCEPT: */
"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "HTTP_ACCEPT_ENCODING: gz
ip, deflate"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "HTTP_HOST: contemplative
christianliving.com"
2011/12/24 22:55:05 [debug] 2660#0: *46 fastcgi param: "HTTP_USER_AGENT: Mozilla
/5.0 (compatible; bingbot/2.0; +http://www.bing.com/bingbot.htm)"
2011/12/24 22:55:05 [debug] 2660#0: *46 http cleanup add: 0000000002463D08
2011/12/24 22:55:05 [debug] 2660#0: *46 [upstream_fair] peer 0 is idle
2011/12/24 22:55:05 [debug] 2660#0: *46 [upstream_fair] chose peer 0
2011/12/24 22:55:05 [debug] 2660#0: *46 [upstream_fair] peer 0 expired weight, r
eset to 1
2011/12/24 22:55:05 [debug] 2660#0: *46 [upstream_fair] fp->current = 0, peer_id
= 0, ret = 0
2011/12/24 22:55:05 [debug] 2660#0: *46 [upstream_fair] nreq for peer 0 @ 000000
00023C8A70/00007F63DB4BA050 now 1, total 1, delta 1
2011/12/24 22:55:05 [debug] 2660#0: *46 socket 22
2011/12/24 22:55:05 [debug] 2660#0: *46 epoll add connection: fd:22 ev:80000005
2011/12/24 22:55:05 [debug] 2660#0: *46 connect to unix:/var/run/php-fpm.sock, f
d:22 #47
2011/12/24 22:55:05 [debug] 2660#0: *46 connected
2011/12/24 22:55:05 [debug] 2660#0: *46 http upstream connect: 0
2011/12/24 22:55:05 [debug] 2660#0: *46 http upstream send request
2011/12/24 22:55:05 [debug] 2660#0: *46 chain writer buf fl:0 s:832
2011/12/24 22:55:05 [debug] 2660#0: *46 chain writer in: 0000000002463D50
2011/12/24 22:55:05 [debug] 2660#0: *46 writev: 832
2011/12/24 22:55:05 [debug] 2660#0: *46 chain writer out: 0000000000000000
2011/12/24 22:55:05 [debug] 2660#0: *46 event timer add: 22: 14400000:1324799705
210
2011/12/24 22:55:05 [debug] 2660#0: *46 http finalize request: -4, "/index.php?q
=/bible/7/PS&" a:1, c:3
2011/12/24 22:55:05 [debug] 2660#0: *46 http request count:3 blk:0
2011/12/24 22:55:05 [debug] 2660#0: *46 http finalize request: -4, "/index.php?q
=/bible/7/PS&" a:1, c:2
2011/12/24 22:55:05 [debug] 2660#0: *46 http request count:2 blk:0
2011/12/24 22:55:05 [debug] 2660#0: *46 post event 00000000024D7348
2011/12/24 22:55:05 [debug] 2660#0: *46 post event 00000000024D73B0
2011/12/24 22:55:05 [debug] 2660#0: *46 delete posted event 00000000024D73B0
2011/12/24 22:55:05 [debug] 2660#0: *46 http upstream request: "/index.php?q=/bi
ble/7/PS&"
2011/12/24 22:55:05 [debug] 2660#0: *46 http upstream dummy handler
2011/12/24 22:55:05 [debug] 2660#0: *46 delete posted event 00000000024D7348
2011/12/24 22:55:05 [debug] 2660#0: *46 http run request: "/index.php?q=/bible/7
/PS&"
2011/12/24 22:55:05 [debug] 2660#0: *46 http upstream check client, write event:
1, "/index.php"
2011/12/24 22:55:05 [debug] 2660#0: *46 http upstream recv(): -1 (11: Resource t
emporarily unavailable)
2011/12/24 22:55:05 [debug] 2660#0: *46 post event 000000000246F3A0
2011/12/24 22:55:05 [debug] 2660#0: *46 post event 00000000024D73B0
2011/12/24 22:55:05 [debug] 2660#0: *46 delete posted event 00000000024D73B0
2011/12/24 22:55:05 [debug] 2660#0: *46 http upstream request: "/index.php?q=/bi
ble/7/PS&"
2011/12/24 22:55:05 [debug] 2660#0: *46 http upstream dummy handler
2011/12/24 22:55:05 [debug] 2660#0: *46 delete posted event 000000000246F3A0
2011/12/24 22:55:05 [debug] 2660#0: *46 http upstream request: "/index.php?q=/bi
ble/7/PS&"
2011/12/24 22:55:05 [debug] 2660#0: *46 http upstream process header
2011/12/24 22:55:05 [debug] 2660#0: *46 malloc: 0000000002464160:4096
2011/12/24 22:55:05 [debug] 2660#0: *46 recv: fd:22 544 of 4006
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi record byte: 01
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi record byte: 06
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi record byte: 00
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi record byte: 01
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi record byte: 02
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi record byte: 03
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi record byte: 05
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi record byte: 00
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi record length: 515
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi parser: 0
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi header: "Status: 301 Moved
Permanently"
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi parser: 0
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi header: "X-Powered-By: PHP/
5.3.6-13ubuntu3.3"
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi parser: 0
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi header: "Set-Cookie: SESS9f
9dd69bfd2d172434d50fc58ea3a1f7=6aellem4b60p509anu5t7eequ0; expires=Tue, 17-Jan-2
012 07:28:25 GMT; path=/; domain=.contemplativechristianliving.com"
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi parser: 0
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi header: "Expires: Sun, 19 N
ov 1978 05:00:00 GMT"
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi parser: 0
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi header: "Last-Modified: Sun
, 25 Dec 2011 03:55:05 GMT"
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi parser: 0
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi header: "Cache-Control: sto
re, no-cache, must-revalidate"
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi parser: 0
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi header: "Cache-Control: pos
t-check=0, pre-check=0"
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi parser: 0
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi header: "Content-Type: text
/html; charset=utf-8"
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi parser: 0
2011/12/24 22:55:05 [debug] 2660#0: *46 posix_memalign: 0000000002465170:4096 @1
6
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi header: "Location: http://c
ontemplativechristianliving.com/bible/7/PS"
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi parser: 1
2011/12/24 22:55:05 [debug] 2660#0: *46 http fastcgi header done
2011/12/24 22:55:05 [debug] 2660#0: *46 lua capture header filter, uri "/index.p
hp"
2011/12/24 22:55:05 [debug] 2660#0: *46 http script var: "MISS"
2011/12/24 22:55:05 [debug] 2660#0: *46 uploadprogress error-tracker error: 0
2011/12/24 22:55:05 [debug] 2660#0: *46 xslt filter header
2011/12/24 22:55:05 [debug] 2660#0: *46 HTTP/1.1 301 Moved Permanently
Server: nginx
Date: Sun, 25 Dec 2011 03:55:05 GMT
Content-Type: text/html; charset=utf-8
Transfer-Encoding: chunked
Connection: keep-alive
Keep-Alive: timeout=10
X-Powered-By: PHP/5.3.6-13ubuntu3.3
Set-Cookie: SESS9f9dd69bfd2d172434d50fc58ea3a1f7=6aellem4b60p509anu5t7eequ0; exp
ires=Tue, 17-Jan-2012 07:28:25 GMT; path=/; domain=.contemplativechristianliving
.com
Expires: Thu, 01 Jan 1970 00:00:01 GMT
Last-Modified: Sun, 25 Dec 2011 03:55:05 GMT
Cache-Control: no-cache
Location: http://contemplativechristianliving.com/bible/7/PS
X-Micro-Cache: MISS

Hmm

perusio's picture

somehow Drupal is not happy with the real request URI with the query string. Try adding an explicit location. Like this:

location = /bible/7/PS {
   try_files $uri /index.php$request_uri;
}

Here you're circumventing the explicit addition of the query string. I suspect that there's some module taking care of replacing the non-clean URIs with clean URIs.

And try to access it afterward.

EDIT: Were you using the default drupal 6 .htaccess that has the rewrite rules for clean URLs before?

Oddly, that doesn't appear to

Chad_Dupuis's picture

Oddly, that doesn't appear to work either. I get the same error and nothing in the error logs - the access logs simply show:

::ffff:76.133.122.111 - - [25/Dec/2011:08:55:57 -0500] "GET /index.php/bible/7/PS HTTP/1.1" 301 5 "-" "Mozilla/5.0 (X11; Linux x86_64; rv:9.0) Gecko/20100101 Firefox/9.0"

And, yes, I was using clean urls with the standard .htaccess before.

epoll_ctl() + php-yyhmsgfpm2fpm.sock failed

Peter Bowey's picture

1) epoll_ctl(1, 0) failed (1: Operation not permitted)

Recompiling nginx without third party 'push module' will solve that.

connect() to unix:/var/run/php-yyhmsgfpm2fpm.sock failed (2: No such file or directory) while connecting to upstream, client: 76.123.113.235, server:

Your Linux socket '/var/run/php-yyhmsgfpm2fpm.sock' does not exist -or has the wrong permissions.

--
Linux: Web Developer
Peter Bowey Computer Solutions
Australia: GMT+9:30
(¯`·..·[ Peter ]·..·´¯)

actually I just switched the

Chad_Dupuis's picture

actually I just switched the dns back to my old server for now as I don't want the site down for more than a day...

If you have any ideas on the configuration errors listed above that I was getting, please let me know.

edit
I just switched it back -- so in a few minutes you should start seeing the error again --- thanks for any info you can provide...

Redirection LOOP

Peter Bowey's picture

You have a continious 're-direction' LOOP!
Header Info:

HTTP/1.1 301 Moved Permanently
Server: nginx
Date: Sun, 25 Dec 2011 00:00:59 GMT
Content-Type: text/html; charset=utf-8
Transfer-Encoding: chunked
Connection: keep-alive
Keep-Alive: timeout=10
X-Powered-By: PHP/5.3.6-13ubuntu3.3
Expires: Thu, 01 Jan 1970 00:00:01 GMT
Last-Modified: Sun, 25 Dec 2011 00:00:59 GMT
Cache-Control: no-cache
Location: http://contemplativechristianliving.com/contact
X-Micro-Cache: BYPASS

The above header goes on 'repeating' until excess errors bomb the GET

#request# GET http://contemplativechristianliving.com/contact
GET /contact
#request# GET http://contemplativechristianliving.com/contact
GET /contact
#request# GET http://contemplativechristianliving.com/contact
GET /contact
#request# GET http://contemplativechristianliving.com/contact
GET /contact
#request# GET http://contemplativechristianliving.com/contact
GET /contact
#request# GET http://contemplativechristianliving.com/contact
GET /contact
#request# GET http://contemplativechristianliving.com/contact
GET /contact
#request# GET http://contemplativechristianliving.com/contact
GET /contact
#request# GET http://contemplativechristianliving.com/contact
GET /contact
#request# GET http://contemplativechristianliving.com/contact
GET /contact
#request# GET http://contemplativechristianliving.com/contact
GET /contact
#request# GET http://contemplativechristianliving.com/contact
GET /contact
#request# GET http://contemplativechristianliving.com/contact
GET /contact
#request# GET http://contemplativechristianliving.com/contact
GET /contact
#request# GET http://contemplativechristianliving.com/contact
GET /contact
#request# GET http://contemplativechristianliving.com/contact
GET /contact
#request# GET http://contemplativechristianliving.com/contact
GET /contact
#request# GET http://contemplativechristianliving.com/contact
GET /contact
#request# GET http://contemplativechristianliving.com/contact
GET /contact
#request# GET http://contemplativechristianliving.com/contact
GET /contact
#request# GET http://contemplativechristianliving.com/contact
GET /contact

--
Linux: Web Developer
Peter Bowey Computer Solutions
Australia: GMT+9:30
(¯`·..·[ Peter ]·..·´¯)

Thanks for the help

Chad_Dupuis's picture

Thanks for the help everyone... what seemed to help was before moving the website over from my old server was to disable global redirects slash function. Even though I did this after the fact via drush, it didn't seem to take.

Now I have everything up and running at http://contemplativechristianliving.com/ ...

but I have am having one tiny problem with perusio's configs. Urls such as http://contemplativechristianliving.com/help/member-instructions#userpoints do not work.

It's the #... part that is causing a 404. Any ideas on how to allow this?

Check the

perusio's picture

debug log. Post the result here or on a paste bin.

This seems to have something

Chad_Dupuis's picture

This seems to have something to do with the pathauto module??

Here is what I can tell:

==
I create a page and save it with a custom url (unsetting set automatic alias and typing one in manually)
At save I am taken to a 404 page
If I then go to admin/content/node I see the node I just created and if I click edit I can edit the page upon save I get the same 404, if I click on the node title from the admin page, I also get the 404....

==
Now, if I create the same page (i.e. same content) but leave automatic alias checked under custom url - it saves fine and the page is reachable...

==
Then if I edit that page, uncheck set automatic alias and put in a custom url manually when I click save it takes me to the 404 page again.

When I'm getting the 404 - the logs simply say the page does not exist

Just as proof :-) -- here is the page I created and left automatic alias checked:
http://contemplativechristianliving.com/help-using-our-site-member-instr... (so the href anchor works fine...)

???

All this is new for me

perusio's picture

never heard of such. But I venture that the problem resides on the Drupal side of things.

Nginx

Group organizers

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds: