View previous topic :: View next topic |
Author |
Message |
zambizzi Guru
Joined: 28 Aug 2004 Posts: 581 Location: Boise Idaho
|
Posted: Mon Sep 13, 2004 9:24 pm Post subject: Apache warnings... |
|
|
I've configured a couple of VirtualHosts in Apache and I'm trying to eliminate any and all warnings or problems resulting from my configuration.
In my current config...I get these warnings when rebooting my server, however, everything works as it should...like I said, I'd just like to get rid of them and understand why I'm getting them:
Code: |
root@localhost user # /etc/init.d/apache2 restart
* Stopping apache2...
apache2: Could not determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
[Tue Sep 14 05:08:08 2004] [warn] NameVirtualHost www.domain.com:80 has no VirtualHosts
[Tue Sep 14 05:08:08 2004] [warn] NameVirtualHost www.domain.com:443 has no VirtualHosts [ ok ] * Starting apache2...
apache2: Could not determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
[Tue Sep 14 05:08:10 2004] [warn] NameVirtualHost www.domain.com:80 has no VirtualHosts
[Tue Sep 14 05:08:10 2004] [warn] NameVirtualHost www.domain.com:443 has no VirtualHosts [ ok ]
|
...as you can see, 2 ports, one for the regular site on 80 and another for 443 for SSL. Each has 2 entries, one for appending www. to the domain and one to call it by domain name only (i.e. www.domain.com/domain.com)
Here is my vhosts.conf file:
Code: |
NameVirtualHost domain.com:80
<VirtualHost 123.123.123.123:80>
DocumentRoot /var/www/localhost/htdocs/domain.com
ServerName domain.com
ErrorLog /var/www/localhost/htdocs/domain.com/logs/domain-error_log
</VirtualHost>
NameVirtualHost www.domain.com:80
<VirtualHost 123.123.123.123:80>
DocumentRoot /var/www/localhost/htdocs/domain.com
ServerName www.domain.com
ErrorLog /var/www/localhost/htdocs/domain.com/logs/domain-error_log
</VirtualHost>
#SSL for both domains...
<IfModule mod_ssl.c>
NameVirtualHost domain.com:443
<VirtualHost 123.123.123.123:443>
DocumentRoot /var/www/localhost/htdocs/domain.com
ServerName supreme-greens.com
ErrorLog /var/www/localhost/htdocs/domain.com/logs/ssl_error_log
<IfModule mod_log_config.c>
TransferLog logs/ssl_access_log
</IfModule>
SSLEngine on
SSLCipherSuite ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP:+eNULL
SSLCertificateFile conf/ssl/domain.com.crt
SSLCertificateKeyFile conf/ssl/domain.com.key
<Files ~ "\.(cgi|shtml|phtml|php?)$">
SSLOptions +StdEnvVars
</Files>
<Directory "/home/httpd/cgi-bin">
SSLOptions +StdEnvVars
</Directory>
<IfModule mod_setenvif.c>
SetEnvIf User-Agent ".*MSIE.*" nokeepalive ssl-unclean-shutdown \
downgrade-1.0 force-response-1.0
</IfModule>
<IfModule mod_log_config.c>
CustomLog /var/www/localhost/htdocs/domain.com/logs/ssl_request_log \
"%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \"%r\" %b"
</IfModule>
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteOptions inherit
</IfModule>
</VirtualHost>
</IfModule>
NameVirtualHost www.domain.com:443
<VirtualHost 123.123.123.123:443>
DocumentRoot /var/www/localhost/htdocs/domain.com
ServerName www.domain.com
ErrorLog /var/www/localhost/htdocs/domain.com/logs/ssl_error_log
<IfModule mod_log_config.c>
TransferLog logs/ssl_access_log
</IfModule>
SSLEngine on
SSLCipherSuite ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP:+eNULL
SSLCertificateFile conf/ssl/domain.com.crt
SSLCertificateKeyFile conf/ssl/domain.com.key
<Files ~ "\.(cgi|shtml|phtml|php?)$">
SSLOptions +StdEnvVars
</Files>
<Directory "/home/httpd/cgi-bin">
SSLOptions +StdEnvVars
</Directory>
<IfModule mod_setenvif.c>
SetEnvIf User-Agent ".*MSIE.*" nokeepalive ssl-unclean-shutdown \
downgrade-1.0 force-response-1.0
</IfModule>
<IfModule mod_log_config.c>
CustomLog /var/www/localhost/htdocs/domain.com/logs/ssl_request_log \
"%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \"%r\" %b"
</IfModule>
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteOptions inherit
</IfModule>
</VirtualHost>
</IfModule>
|
What am I doing wrong? Is there a better (perhaps less verbose) way of doing the same thing?
Thanks!! |
|
Back to top |
|
|
Shopro l33t
Joined: 12 May 2004 Posts: 678 Location: Dayton, OH, USA
|
Posted: Wed Sep 15, 2004 5:15 am Post subject: |
|
|
I remember reading somewhere that apache has problems when using ssl and enabling vhosts. I'll try to look it up somewhere and post a possible fix for it. |
|
Back to top |
|
|
Shopro l33t
Joined: 12 May 2004 Posts: 678 Location: Dayton, OH, USA
|
|
Back to top |
|
|
|
|
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 You cannot vote in polls in this forum
|
|