nginx: [emerg] unknown directive "passenger_enabled"
In my opinion, nginx in a way is better than Apache. It has low memory footprint and configuring it was easier and in straightforward manner. I was helping out a friend who is a Ruby On Rails developer migrating his Apache based server to Nginx couple of days back. When he tried to start nginx server, he got these error messages :
nginx: [emerg] unknown directive "passenger_enabled" in /etc/nginx/conf.d/default.conf:6
nginx: configuration file /etc/nginx/nginx.conf test failed
Upon further investigation, the error messages indicate that nginx was compiled without Phusion Passenger support.
To fix this :
sudo gem install passenger
cd /var/lib/gems/1.9.1/gems/passenger-2.2.11/bin
sudo ./passenger-install-nginx-module
restart nginx and the error message is gone.
References :
By Adam Ng
IF you gain some knowledge or the information here solved your programming problem. Please consider donating to the less fortunate or some charities that you like. Apart from donation, planting trees, volunteering or reducing your carbon footprint will be great too.
Advertisement
Tutorials
+11.2k Golang : Web routing/multiplex example
+9.1k Golang : What is the default port number for connecting to MySQL/MariaDB database ?
+6.4k Golang : Test input string for unicode example
+5.8k Unix/Linux/MacOSx : Get local IP address
+6.2k Fix ERROR 2003 (HY000): Can't connect to MySQL server on 'IP address' (111)
+14k Golang : unknown escape sequence error
+23k Golang : Gorilla mux routing example
+19.7k Golang : Close channel after ticker stopped example
+17.6k Golang : Get future or past hours, minutes or seconds
+12k Golang : Convert(cast) bigint to string
+15.3k Golang : How to add color to string?
+10.4k Golang : Embed secret text string into binary(executable) file