Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm hosting my website on my own server running OSX 10.6.6. I have the main site up all fine with pointing to my IP address (and hence the /Library/WebServer/Documents/ directory). My blog is located at but I would like to add to access it through My understanding is that I need to enable virtual hosts but I can't seem to get it to work properly.

So far, I've enabled the virtual host bit in /private/etc/apache2/httpd.conf. I've added

<VirtualHost *:80>
DocumentRoot "Library/WebServer/Documents/blog"

to /private/etc/apache2/extra/httpd-vhosts.conf and

to /private/etc/hosts. After restarting apache, not only does not work, but I get the message

Forbidden You don't have permission to access /blog/ on this server.

I'd appreciate any help you guys can give. Thanks Chris

share|improve this question
up vote 1 down vote accepted

Check your httpd.conf for your Allow/Deny permissions. You probably need to add a <Directory /Library/Webserver/Documents/blog> directive within the VirtualHost to allow accessibility.

Also, you're missing your leading / in the VirtualHost path.

share|improve this answer
Thanks for that. My user/group are both set to _www and everything now seems to work when I set the ServerName line in httpd.conf to However, using the above settings (albeit with the corrected leading /), directs me to (or /Library/WebServer/Documents). Am I still doing something wrong? – Chris Robinson Jan 26 '11 at 8:41
I assume in your vhosts.conf you have added/uncommented 'NameVirtualHost *', correct? You could try moving to a vhost as well to see if it continues to override blog. – M. Early Jan 26 '11 at 20:32

you should use Server Admin for such a task. The reason is that it's not easier or better but if you make any changes from the command line, you will get Server Admin GUI out of sync with the real status of the configuration. To solve your problem use Redirect Directive. More info is here:

share|improve this answer
Sorry I should mentioned that I am running 10.6.6 client, not server. Can you recommend another GUI for server admin? – Chris Robinson Jan 26 '11 at 10:01
Oh, I was confused from your original post. Follow the link I sent you if you want to go the command line way. Otherwise install a control panel like Webmin, Plesk etc. Just google for it – BobC Jan 26 '11 at 12:11

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.