Forum Moderators: phranque
httpd.conf is et up correctly Im suredue to the fact when I input the web address I am getting the default home page (apache/centos) for each domain...BUT...I cannot see any individual pages within the virtual hosts directories...
A few others have had this problem on CentOS 4 but it was apparently down to selinux which I have totally disabled!**! Centos is the same as RHEL4 for those that are unsure! and the centos forum is useless and their support non existant...
Here is an exercpt from my error_log
CentOS 4.1 Apache 2.0.52 server. User is Apache / group is apache
I have commented out IPs for security//
File does not exist: /var/www/html/xmlsrv
[Mon Jan 09 23:10:41 2006] [error] [client 22.***.81.10] File does not exist: /var/www/html/xmlsrv
[Tue Jan 10 00:55:21 2006] [error] [client xx.***.#*$!.xxx] Directory index forbidden by rule: /var/www/html/
[Tue Jan 10 00:55:27 2006] [error] [client xx.xxx.xxx.xxx File does not exist: /var/www/html/index.html
[Tue Jan 10 00:55:30 2006] [error] [client xx.xxx.xxx.xxx] Directory index forbidden by rule: /var/www/html/
[Tue Jan 10 00:55:39 2006] [error] [client xx.xxx.xxx.xxx Directory index forbidden by rule: /var/www/html/
[Tue Jan 10 00:58:58 2006] [notice] caught SIGTERM, shutting down
[Tue Jan 10 00:58:58 2006] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
[Tue Jan 10 00:58:58 2006] [notice] Digest: generating secret for digest authentication ...
[Tue Jan 10 00:58:58 2006] [notice] Digest: done
[Tue Jan 10 00:58:58 2006] [notice] LDAP: Built with OpenLDAP LDAP SDK
[Tue Jan 10 00:58:58 2006] [notice] LDAP: SSL support unavailable
[Tue Jan 10 00:58:58 2006] [notice] Apache/2.0.52 (CentOS) configured -- resuming normal operations
[Tue Jan 10 00:59:13 2006] [error] [client xx.xxx.xxx.xxx] Directory index forbidden by rule: /var/www/html/
[Tue Jan 10 01:00:41 2006] [error] [client xx.xxx.xxx.xxx] Directory index forbidden by rule: /var/www/html/
[Tue Jan 10 01:00:46 2006] [error] [client xx.xxx.xxx.xxx] File does not exist: /var/www/html/test.html
[Tue Jan 10 01:00:50 2006] [error] [client xx.xxx.xxx.xxx] File does not exist: /var/www/html/test.htm
[Tue Jan 10 01:02:07 2006] [error] [client xx.xxx.xxx.xxx] File does not exist: /var/www/html/test.html
[Tue Jan 10 01:02:21 2006] [error] [client xx.xxx.xxx.xxx] File does not exist: /var/www/html/test.html
[Tue Jan 10 01:02:22 2006] [error] [client xx.xxx.xxx.xxx] File does not exist: /var/www/html/test.html
[Tue Jan 10 01:02:23 2006] [error] [client xx.xxx.xxx.xxx] File does not exist: /var/www/html/test.html
[Tue Jan 10 01:02:27 2006] [error] [client xx.xxx.xxx.xxx] Directory index forbidden by rule: /var/www/html/
As I said above SELINUX is now disabled! I have checked several times and it is not turned on so what could be the problem>>?
PLEASE...ANY HELP GRATEFULL RECEIVED!
I can post my httpd.conf "if" needed though I dont think its the problem?
[edited by: jdMorgan at 2:24 am (utc) on Feb. 3, 2006]
[edit reason] Obscured IP addresses. [/edit]
Ok guys. A 2nd post made clearer as 1st one got ZERO replies :(
Basically. My RHEL 4 based server is not serving Virtual Hosts properly at all! I can resolve the domain names (all of the vhost ones) to the correct ip which is the one below and if I go to say www.mydomain2.co.uk it brings up the apache working page no problem. BUT.
When I try and put files in the site say test.html or even index.html the error message as seen in the log below are coming up saying file not found! (all permissions are correct imo)
I have heard others had this same issue but it was down to SElinux but I have this turned off so I am truly baffled as to what to do :/
ANY IDEAS PLEASE!
THANKS IF ANYONE CAN HELP
My error_log from apache
I have commented out IPs for security//
File does not exist: /var/www/html/xmlsrv
[Mon Jan 09 23:10:41 2006] [error] [client 22.***.81.10] File does not exist: /var/www/html/xmlsrv
[Tue Jan 10 00:55:21 2006] [error] [client xx.***.#*$!.xxx] Directory index forbidden by rule: /var/www/html/
[Tue Jan 10 00:55:27 2006] [error] [client xx.xxx.xxx.xxx] File does not exist: /var/www/html/index.html
[Tue Jan 10 00:55:30 2006] [error] [client xx.xxx.xxx.xxx] Directory index forbidden by rule: /var/www/html/
[Tue Jan 10 00:55:39 2006] [error] [client xx.xxx.xxx.xxx Directory index forbidden by rule: /var/www/html/
[Tue Jan 10 00:58:58 2006] [notice] caught SIGTERM, shutting down
[Tue Jan 10 00:58:58 2006] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
[Tue Jan 10 00:58:58 2006] [notice] Digest: generating secret for digest authentication ...
[Tue Jan 10 00:58:58 2006] [notice] Digest: done
[Tue Jan 10 00:58:58 2006] [notice] LDAP: Built with OpenLDAP LDAP SDK
[Tue Jan 10 00:58:58 2006] [notice] LDAP: SSL support unavailable
[Tue Jan 10 00:58:58 2006] [notice] Apache/2.0.52 (CentOS) configured -- resuming normal operations
[Tue Jan 10 00:59:13 2006] [error] [client xx.xxx.xxx.xxx] Directory index forbidden by rule: /var/www/html/
[Tue Jan 10 01:00:41 2006] [error] [client xx.xxx.xxx.xxx] Directory index forbidden by rule: /var/www/html/
[Tue Jan 10 01:00:46 2006] [error] [client xx.xxx.xxx.xxx] File does not exist: /var/www/html/test.html
[Tue Jan 10 01:00:50 2006] [error] [client xx.xxx.xxx.xxx] File does not exist: /var/www/html/test.htm
[Tue Jan 10 01:02:07 2006] [error] [client xx.xxx.xxx.xxx] File does not exist: /var/www/html/test.html
[Tue Jan 10 01:02:21 2006] [error] [client xx.xxx.xxx.xxx] File does not exist: /var/www/html/test.html
[Tue Jan 10 01:02:22 2006] [error] [client xx.xxx.xxx.xxx] File does not exist: /var/www/html/test.html
[Tue Jan 10 01:02:23 2006] [error] [client xx.xxx.xxx.xxx] File does not exist: /var/www/html/test.html
[Tue Jan 10 01:02:27 2006] [error] [client xx.xxx.xxx.xxx] Directory index forbidden by rule: /var/www/html/
PLEASE...ANY HELP GRATEFULL RECEIVED! ALso, I have tried indexes on, symlinks etc
and the Virtual Host bit of my httpd.conf (for one virtual host with IP changed to dummy and domain name adjusted for safety)
#
# Use name-based virtual hosting.
#
NameVirtualHost 82.***.31.11:80
#
# NOTE: NameVirtualHost cannot be used without a port specifier
# (e.g. :80) if mod_ssl is being used, due to the nature of the
# SSL protocol.
#
<VirtualHost 82.***.31.11:80>
ServerAdmin webmaster@mydomain2co.uk
DocumentRoot /var/www/html/mydomain2.co.uk
ServerName mydomain2.co.uk
ErrorLog /var/log/httpd/mydomain2.co.uk/mydomain2-errorlog
CustomLog /var/log/httpd/mydomain2.co.uk/mydomain2-accesslog combined
Options ALL
</VirtualHost>
#<VirtualHost *:80>
# ServerAdmin webmaster@dummy-host.example.com
# DocumentRoot /www/docs/dummy-host.example.com
# ServerName dummy-host.example.com
# ErrorLog logs/dummy-host.example.com-error_log
# CustomLog logs/dummy-host.example.com-access_log common
#</VirtualHost>
Mods. Please feel free to delete my original post is still no replies! TItled
" Apache 2.0.52-12.1.centos4 and no virtual hosts will serve. "
[edited by: jdMorgan at 2:26 am (utc) on Feb. 3, 2006]
[edit reason] Obscured IP addresses. [/edit]
Just make sure everything matches! Hostname, DNS records, Apache virtual server names. That's the only things I touched and it works now.. So that's my advice. Sorry I can't give you anything specific. Also after it started working I still get the LDAP SSL unavailable message so that's not the problem.
Grant