Click to See Complete Forum and Search --> : refusing to connect to http://localhost!
dijit
04-09-2003, 03:59 AM
Hi,
For the past week I have been trying to configure apache with SSL,
anyway,
I can't even get it to connect to http://localhost anymore!
I can't see why
All I have done is add the following to the httpd.conf file:
Listen 443
<VirtualHost https://jj.mandrake:443>
#ServerName jj.mandrake
ErrorLog /etc/httpd/logs/error_log
TransferLog /etc/httpd/logs/acces_log
SSLEngine on
SSLCertificateFile /conf/ssl.crt
SSLCertificateKeyFile /conf/ssl.key
#SSLVerifyClient require
#SSLCACertificateFile /conf/ssl.crt
</VirtualHost>
I am getting the error when restarting httpd "port must be numeric"
it is numeric isn't it ?!
:confused: can anyone help?
mrBen
04-09-2003, 04:17 AM
What about http://localhost:443
And try http://127.0.0.1 and 127.0.0.1:443 while you're at it ;)
dijit
04-09-2003, 04:33 AM
they are all refused!
chrism01
04-09-2003, 09:29 AM
neither of my books have https or http in the <VirtualHost ...> directive. I think it deduces the port as the first thing after a ':' so directive should be:
<VirtualHost <ip or name>:port>
bwkaz
04-09-2003, 09:45 AM
Yeah, chrism01's answer makes sense to me.
Another way of saying the same thing is, Apache thinks (since it sees a colon after the http) that your port is "//jj.mandrake:443" instead of "443". It thinks your hostname is "http".
dijit
04-09-2003, 12:29 PM
yes, you're right
it goes past that now
I am now left with this error:
Syntax error on line 180 of /etc/httpd/conf/httpd.conf:
Invalid command 'SSLEngine', perhaps mis-spelled or defined by a module not included in the server configuration
If I comment this out, it goes to the next line and gives the same error:
Syntax error on line 180 of /etc/httpd/conf/httpd.conf:
Invalid command 'SSLCertificatePath', perhaps mis-spelled or defined by a module not included in the server configuration
Syntax error on line 181 of /etc/httpd/conf/httpd.conf:
Invalid command 'SSLCertificateFile', perhaps mis-spelled or defined by a module not included in the server configuration
Do you know why this is ?
I was thinking...
because I installed apache, ssl, php etc by doing an upgrade to mandrake, from the disks,
it installed each of them fine, but not togethor ?
this is the impression i get from searching on google
however, nothing concrete, and certainly i cant find anything on how i can change this
any ideas?
edit:
if i type httpd -l
it returns
Compiled-in modules:
http_core.c
mod_so.c
suexec: enabled; valid wrapper /usr/sbin/suexec
(though i am not sure if this is good or not :) )
bwkaz
04-09-2003, 01:23 PM
Somewhere higher up in the config file, there's a list of modules that the server should load. Add mod_ssl.o (or whatever the name of it is) to this list; that should define the SSL* directives.
dijit
04-09-2003, 01:34 PM
yep thats already in there
as
<IfDefine HAVE_SSL>
AddModule mod_ssl.c
</IfDefine>
:confused:
bwkaz
04-09-2003, 09:29 PM
But ... is HAVE_SSL defined if the module isn't loaded?
I'd bet not... What happens if you get rid of the IfDefined directives, and just leave the AddModule mod_ssl.c?
Or perhaps the problem is that the module is there, but Apache itself doesn't realize it (and therefore doesn't set HAVE_SSL)? You installed Apache from RPMs, though, so you have no idea how it was configured...