Linode Forum
Linode Community Forums
 FAQFAQ    SearchSearch    MembersMembers      Register Register 
 LoginLogin [ Anonymous ] 
Post new topic  Reply to topic
Author Message
PostPosted: Mon Jun 17, 2013 2:32 am 
Offline
Newbie

Joined: Mon Jun 17, 2013 2:08 am
Posts: 3
I have 2 SSL websites I'm trying to serve from a Linode with 2 IP addresses (Apache/Fedora). I had no trouble with setting up the vhost.conf to support the 2 websites for http access, one per IP address. But the SSL part is tripping me up.

I have the 1st site working with 1 IP address. But when I add the second <virtualhost> entry in ssl.conf, and then do 'service httpd restart', it fails with:
Quote:
Restarting httpd (via systemctl): Job failed. See system logs and 'systemctl status' for details.
[FAILED]


There's nothing in either the vhost or ssl error log, so I'm not clear what's failing (though I've gotten "caught SIGTERM, shutting down" with some tweaks.

If I remove the 2nd <virtualhost> from ssl.conf, the restart works. I can use either website in http, but of course only the 1st with https.

The 2nd <virtualhost> I remove looks like (where 1.2.3.4 is the 2nd IP address, and mysite.com is my 2nd website):
Code:
<VirtualHost 1.2.3.4:443>
     DocumentRoot "/srv/www/mysite.com/public_html/"
     ServerName http://www.mysite.com

     ErrorLog logs/ssl_error_log
     TransferLog logs/ssl_access_log
     LogLevel warn

     SSLEngine On
     SSLProtocol all -SSLv2
     SSLCipherSuite RC4-SHA:AES128-SHA:ALL:!ADH:!EXP:!LOW:!MD5:!SSLV2:!NULL

     SSLCertificateFile /etc/httpd/ssl/www_mysite_com.crt
     SSLCertificateKeyFile /etc/httpd/ssl/www.mysite.com.key
     SSLCertificateChainFile /etc/httpd/ssl/the_bundle.crt
</VirtualHost>

Any help would be most appreciated!


Top
   
PostPosted: Mon Jun 17, 2013 2:39 am 
Offline
Senior Member

Joined: Sun Apr 26, 2009 3:37 am
Posts: 72
Website: http://wiggenhorn.org/
Probably shouldn't have "http://" in the ServerName.


Top
   
PostPosted: Mon Jun 17, 2013 2:43 am 
Offline
Senior Member
User avatar

Joined: Thu Feb 16, 2012 9:01 pm
Posts: 52
apache2ctl configtest

and/or read the error logs


Top
   
PostPosted: Mon Jun 17, 2013 4:02 am 
Offline
Newbie

Joined: Mon Jun 17, 2013 2:08 am
Posts: 3
Okay, just so I don't send somebody else off in a mixed up direction... apachectl configtest (which works for my Apache 2.2 instance) revealed the problem... a problem with my .key file. Oops. That's embarrassing. I didn't really have http:// in the ServerName (not sure why I typed that :-?).

Anyway, correcting the .key file and re-key-ing solved the problem. Thanks for the apachectl configtest suggestion!


Top
   
PostPosted: Mon Jun 17, 2013 4:11 am 
Offline
Senior Member

Joined: Mon Aug 29, 2011 2:34 am
Posts: 77
whatisron wrote:
I didn't really have http:// in the ServerName (not sure why I typed that :-?).


This is why we recommend that you don't redact or change information when you post config files or logs. It's 10 times easier to debug issues when we're seeing the same things you are.

-Doug


Top
   
PostPosted: Mon Jun 17, 2013 4:26 pm 
Offline
Newbie

Joined: Mon Jun 17, 2013 2:08 am
Posts: 3
Duly noted... I actually thought I'd copied/pasted from the .conf file, so I'm not sure how that happened. In any case, apologies for that -- I do get the problem you're pointing out!


Top
   
PostPosted: Tue Jun 18, 2013 10:25 pm 
Offline
Senior Member
User avatar

Joined: Sun Jan 18, 2009 2:41 pm
Posts: 830
whatisron wrote:
I didn't really have http:// in the ServerName (not sure why I typed that :-?).

You probably didn't. The forum often adds it to the beginning when it sees http://www.something. (As evidence, I did not type the preceding sentence with a link or http prefix.)


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic


Who is online

Users browsing this forum: No registered users and 4 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
RSS

Powered by phpBB® Forum Software © phpBB Group