Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the '10.5: Apache 2 site troubles with permissions and folders' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
10.5: Apache 2 site troubles with permissions and folders
Authored by: KenDRhyD on Nov 12, '07 06:02:39AM
I have made the following changes:
  1. Edited /private/etc/hosts to add the line 127.0.0.1 d2.test
  2. Edited /private/etc/apache2/httpd.conf to enable the PHP2 and fast CGI load modules, to change the ServerAdmin to my email address, edited the Directory entry to read Allow from all, and uncommented the line Include /private/etc/apache2/extra/httpd-vhosts.conf. Note that I did not edit the #ServerName www.example.com:80 line, leaving it as original (commented out).
  3. I edited the /private/etc/apache2/extra/httpd-vhosts.conf file to add the entry for my d2.test site, as noted in the earlier posting
Often when I start web sharing and try to visit my default web site, but if I stop and start it again it usually works. So my default (~krallen) web site it loading.

When I enter d2.test as the URL, I get a page that indicates Safari can't open the page "http://d2.test/" because it could not connect to the server "d2.test".

I cannot see that I am missing anything or doing anything wrong, but it will not load the alternate site. Please provide any insights possible.

[ Reply to This | # ]

10.5: Apache 2 site troubles with permissions and folders
Authored by: KenDRhyD on Nov 12, '07 06:20:47AM
Some additional tests reveal that the problem is more odd than I suspected.

As a test, I modified the index.html file in my default site (~krallen) to include a link to the root of my alternate site:

<p><a href='./D2TestSite/index.php'>D2 Test Site link</a></p>
If I leave the Include /private/etc/apache2/extra/httpd-vhosts.conf line commented out, then the link works (except that my page is not host rooted properly, so the code in the page does not work as expected.

If I uncomment the Include /private/etc/apache2/extra/httpd-vhosts.conf line (and stop and restart web sharing), then I almost always get an error when I click on the preferences link to my default site: Safari can't open the page "http://172.16.1.200/~krallen/" because it could not connect to the server "172.16.1.200".. Every once in a while I get the default site to load with the line uncommented, but then that new link fails with a similar error, but the URL now has my alternate site directory appended.

Arrgghh!

[ Reply to This | # ]