Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm adding an SSL domain to a host. When I try to restart Nginx, it protests:

Restarting nginx: [emerg]: the "ssl" parameter requires ngx_http_ssl_module in /etc/nginx/sites-enabled/my_site_conf:16

This is frustrating because I actually rebuilt Nginx and Passenger specifically in order to make ngx_http_ssl_module available; it wasn't in the running instance, so I took the opportunity to build with Nginx 0.8.53 and Passenger 3.0.1.

The relevant configuration block is

server {
        listen default ssl;

        ssl_certificate  /etc/nginx/ssl/our-site.crt;
        ssl_certificate_key  /etc/nginx/ssl/our-site.key;

        ssl_session_timeout  5m;

        ssl_protocols  SSLv2 SSLv3 TLSv1;
        ssl_ciphers  ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP;
        ssl_prefer_server_ciphers   on;

...etc. etc. (obviously I've obscured the host name, don't need this question coming up in searches for that domain.)

  • How can I be sure the running Nginx instance has the SSL module active?
  • Am I missing something obvious here?
share|improve this question
Run nginx -V through SSH to verify it was built with SSL support. Also make sure it's been restarted and doesn't have multiple processes running. – Martin Fjordvald Dec 14 '10 at 3:10
Martin, your comment was the closest to the real solution; could you provide it as an answer? – pjmorse Dec 16 '10 at 15:38
this solved my issue too, SSL support isn't included by default. "This module is not built by default, it should be enabled with the --with-http_ssl_module configuration parameter. " – mlathe May 18 at 17:07

You are missing the SSL on directive.

share|improve this answer
it already enabled in "listen" directive – ghloogh Dec 14 '10 at 19:25
As noted in the documentation, "Since Nginx version 0.7.14 the preferred way of enabling SSL is by using the ssl parameter of the listen directive" – pjmorse Dec 15 '10 at 12:47
up vote 0 down vote accepted

Looks like the real problem was that my init script (in /etc/init.d/nginx) was still calling the old version of Nginx, the one without the SSL module, because of a $PATH issue. Fixing some symlinks and deleting the old version fixed the problem.

share|improve this answer

Your Answer


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

Not the answer you're looking for? Browse other questions tagged or ask your own question.