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
+4.8k nginx : force all pages to be SSL
+11.3k Golang : Remove or trim extra comma from CSV
+3.8k Golang : Experimental Jawi programming language
+7.6k Golang : Combine slices but preserve order example
+5.8k How to let Facebook Login button redirect to a particular URL ?
+11k Android Studio : Highlight ImageButton when pressed on example
+48.7k Golang : Disable security check for HTTPS(SSL) with bad or expired certificate
+7.9k Golang : How to get username from email address
+5.6k Golang : Humanize and Titleize functions
+12.7k Golang : How to pass map to html template and access the map's elements
+25.1k Golang : Encrypt and decrypt data with AES crypto
+4.7k Javascript : How to refresh page with JQuery ?