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
+7.4k Golang : Generate Datamatrix barcode
+22.1k Golang : Fix type interface{} has no field or no methods and type assertions example
+28.6k Golang : How to get HTTP request header information?
+15k Golang : Get file permission
+17.9k Golang : Get current URL example
+13.3k Golang : How to filter a map's elements for faster lookup
+5.1k Javascript : Get operating system and browser information
+16.5k Convert JSON to CSV in Golang
+19.9k Golang : Encrypt and decrypt data with TripleDES
+11.3k Golang : Covert map/slice/array to JSON or XML format
+3.7k MariaDB/MySQL : How to get version information
+7.8k Golang : Build and compile multiple source files