I did notice that the DocumentRoot in the 'Main server configuration' section is /var/www/html. I messed around with that to see if I could get the /home/httpd/webdev/html directory working. Unfortunately I couldn't therefore I changed the DocumentRoot to /var/www/webdev/html and everything is working fine.There is obviously something funny with your setup that we are not privvy to. If you're saying that /home/httpd/webdev/html and /var/www/webdev/html are the same directory, then; - one is a symbolic link of the other, or - you have mounted the same disk-volume in two places, or - some other clever thing
/home/httpd/webdev/html and /var/www/webdev/html are two seperate directories with no symbolic link to the other.
In any case, /home/httpd/webdev/html no longer sounds like a plain directory under "/" so it is hardly suprising you get funny results. Of course, all this would be revealed immediately if you were to do: cd / ls -d cd /home ls -d cd /home/html ls -d cd /home/html/webdev ls -d As requested previously...
and... here's the results from / to /home/httpd/webdev/html and from / to /var/www/webdev/html
From / to /var/www/webdev/html [root@webdev /]# ls -ld drwxr-xr-x 24 root root 4096 Mar 1 15:01 . [root@webdev /]# cd var [root@webdev var]# ls -ld drwxr-xr-x 21 root root 4096 Mar 2 08:48 . [root@webdev var]# cd www [root@webdev www]# ls -ld drwxr-xr-x 11 root root 4096 Mar 2 10:23 . [root@webdev www]# cd webdev [root@webdev webdev]# ls -ld drwxr-xr-x 5 root www 4096 Mar 2 09:20 . [root@webdev webdev]# cd html [root@webdev html]# ls -ld drwxr-xr-x 2 root www 4096 Mar 2 10:28 . [root@webdev html]# From / to /home/httpd/webdev/html [root@webdev /]# ls -ld drwxr-xr-x 24 root root 4096 Mar 1 15:01 . [root@webdev /]# cd home [root@webdev home]# ls -ld drwxr-xr-x 4 root root 4096 Mar 1 15:07 . [root@webdev home]# cd httpd [root@webdev httpd]# ls -ld drwxr-xr-x 6 root root 4096 Mar 1 11:21 . [root@webdev httpd]# cd webdev [root@webdev webdev]# ls -ld drwxr-xr-x 5 root www 4096 Mar 1 11:21 . [root@webdev webdev]# cd html [root@webdev html]# ls -ld drwxr-xr-x 2 root www 4096 Mar 1 11:41 . [root@webdev html]# [root@webdev html]# ls -l /home/httpd/webdev/html total 16 -rwxrw-r-- 1 root www 10 Mar 1 11:41 index.htm -rwxr-xr-x 1 root www 20 Mar 1 11:41 index.php [root@webdev html]# [root@webdev html]# ls -l /var/www/webdev/html total 16 -rw-rw-r-- 1 root www 26 Mar 2 10:28 index.htm -rw-r--r-- 1 root www 20 Mar 2 08:50 index.php [root@webdev html]# Hope this explains something?Here's the <VirtualHost> when I get the warning about DocumentRoot doesn't exist and the 403 Forbidden. (DocumentRoot is /home/httpd/webdev/html)
<VirtualHost *:80> ServerAdmin webmaster@xxxxxxxxxxxxx DocumentRoot /home/httpd/webdev/html #DocumentRoot /var/www/webdev/html #ServerName DirectoryIndex index.php index.htm index.html index.cgi #ScriptAlias /cgi-bin/ "/var/www/webdev/cgi-bin/" ScriptAlias /cgi-bin/ "/home/httpd/webdev/cgi-bin/" ErrorLog logs/error_log CustomLog logs/access_log combined </VirtualHost>Here's the <VirtualHost> when I do not get the warning or the 403 Forbidden. (DocumentRoot is /var/www/webdev/html)
<VirtualHost *:80> ServerAdmin webmaster@xxxxxxxxxxxxx #DocumentRoot /home/httpd/webdev/html DocumentRoot /var/www/webdev/html #ServerName DirectoryIndex index.php index.htm index.html index.cgi ScriptAlias /cgi-bin/ "/var/www/webdev/cgi-bin/" #ScriptAlias /cgi-bin/ "/home/httpd/webdev/cgi-bin/" ErrorLog logs/error_log CustomLog logs/access_log combined </VirtualHost> --------------------------------------------------------------------- The official User-To-User support forum of the Apache HTTP Server Project. See <URL:http://httpd.apache.org/userslist.html> for more info. To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx " from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx
![]() |