15

I am trying to support HTTPS traffic with the mod_ssl module on my website. I am running an Amazon EC2 instance for my server. I have installed and configured the basic LAMP packages. However, when I go to put in SSL-specific commands in my apache config files (ie. SSLEngine, SSLCertificateFile, etc) it spits out an error and says that I have a syntax error or the module is not loaded.

My next step was to try $ sudo yum install mod_ssl. However, yum comes back and says, "Processing Conflict...Error: httpd24-tools conflicts with httpd-tools". So, I figured that mod_ssl is included in the httpd-tools package. I then ran $ sudo yum install httpd24-tools but it comes back and tells me I already have that package installed.

Now how come I have the httpd-tools package installed, and mod_ssl is not loaded in my system? Isn't mod_ssl included in the httpd-tools package? I created a test php file <?php echo phpinfo(); ?> just to make sure. My suspicions were confirmed—no 'mod_ssl' is listed under the apache2handler loaded modules table in phpinfo.

So, I'm not exactly sure how to load in/install/configure mod_ssl with the Amazon Linux AMI's. Any help would be appreciated. Here's my current specs:

  • Amazon Linux AMI 2012.09
  • Apache 2.4
  • PHP 5.4

Ran this command to setup server:

$ sudo yum install httpd24 php54 php54-devel php54-mysql php54-common php54-gd php54-xml php54-mbstring php54-mcrypt php54-pecl-apc mysql-server mod_ssl openssl httpd54-devel mysql libjpeg libpng phpmyadmin
5
  • What Apache config did you use? I'd guess syntax error over module not loaded, as it should be standard in most distributions at this point.
    – ceejayoz
    Commented Jan 15, 2013 at 17:17
  • 8
    Came across an answer while scouring forums. "All Apache modules built for httpd-2.4 have been renamed mod24_<name>. So for the SSL Apache module the package is called mod24_ssl." Solution: $ sudo yum install mod24_ssl. This installed the package successfully, but now when I try and restart my Apache server, it fails to start httpd. Any thoughts?
    – kaffolder
    Commented Jan 15, 2013 at 17:28
  • Check your logs.
    – ceejayoz
    Commented Jan 15, 2013 at 17:33
  • :) Sometimes it's the easy things. ;) All I had to do was tweak a few settings in my /etc/httpd/conf.d/ssl.conf file. Good to go! Thanks for the help!
    – kaffolder
    Commented Jan 15, 2013 at 17:36
  • 1
    Please add your answer on the answers section and mark it as answered. I had the same problem and did come across this answer but i didn't read the comments until days later when i realized it actually had the answer.
    – Pochi
    Commented Jan 26, 2014 at 11:36

1 Answer 1

34

Try to run yum install mod24_ssl instead, which I think you've already done. Any packages that have additional versions usually require the version to be specified for any dependencies. So everything for php54 would be prefixed with php54-.

If you're ever unsure, you can always do a yum search with some keywords. For example: yum search mod ssl lists the available packages.

4
  • No problems, glad you got it to work! :)
    – jaseeey
    Commented Apr 10, 2014 at 2:32
  • 2
    OMG, Works perfectly!
    – Fengya Li
    Commented Oct 20, 2015 at 4:52
  • No problems, glad it was some help over a year later :)
    – jaseeey
    Commented Oct 20, 2015 at 5:16
  • Works like a charm Commented Oct 16, 2016 at 0:24

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .