Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I have been trying to get my Passenger and Nginx setup to work with php files but I am having problems with the PCRE regular expressions library. Install all went fine so I'm assuming it found the libraries at that point but now when I include a regex for PHP files in my nginx.conf file, I get the following error when trying to start the server:

nginx: [emerg] using regex "\.php$" requires PCRE library in /home/dev/nginx/conf/nginx.conf:59

I have installed packages with

apt-get install libpcre3 libpcre3-dev

and have installed PCRE 8.21 in usr/local/lib but nothing seems to be working. Is there a simple way to set the path to the library with Nginx or another solution? All problems relating to this seem to prevent Nginx from installing in the first place but succeed once the libraries are installed.

Would really appreciate any help!

Tom

share|improve this question

1 Answer 1

Nginx is different from Apache. If you want PCRE support enabled you have to recompile it. If you installed Nginx from passenger gem, you should execute again the passenger-install-nginx-module

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.