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 have three Virtual Hosts running in apache2 on my personal Macintosh running OS X Mavericks and I have ran into a knot of confusion. They are configured in my httpd-vhosts.conf file as follows:

<VirtualHost *:80>
DocumentRoot "/Library/WebServer/Documents"
ServerName localhost
ServerAlias localhost
<VirtualHost *:80>
DocumentRoot "/Library/WebServer/Documents/dev1"
ServerName dev1.local
ServerAlias www.dev1.local
<VirtualHost *:80>
DocumentRoot "/Library/WebServer/Documents/dev2"
ServerName dev2.local
ServerAlias www.dev2.local
<VirtualHost *:80>
DocumentRoot "/Library/WebServer/Documents/dev3”
ServerName dev3.local
ServerAlias www.dev3.local

Note: The first entry allows me to type in "localhost" and have it load as you'd expect it to without Virtual Hosts running.

dev1 and dev2 work fine, but I get an Error 404 saying "The requested URL / was not found on this server." when I try to load dev3 on the local machine. All three Dev folders have the same permissions I have verified the names. When I checked the error_log I found this:

[Fri Jan 24 12:55:07 2014] [error] [client] File does not exist: /Library/WebServer/Documents/dev3\xe2\x80\x9d

Does anyone know why Apache is appending a "\xe2\x80\x9d" to the end of the Folder path, or why dev3 isn't loading? (I suspect these randomly appended characters are why) Any input welcome! Thanks for reading!

share|improve this question
up vote 8 down vote accepted
DocumentRoot "/Library/WebServer/Documents/dev3”
                                               ^----- no proper quotation mark :9

If you have php installed:

echo "\xe2\x80\x9d";

// or

echo utf8_decode("\xe2\x80\x9d");

// should give you ”
share|improve this answer
makes a "Not Bad" face and face palms hand through head Now see, that makes so much sense. This happens to me with HTML forms too... THANK YOU! I've been scratching my head for an hour about this. How does that character get typed out versus the regular quotation mark @DanFromGermany ? – Uncle Nerdicus Jan 24 '14 at 18:21
@UncleNerdicus depends on your text editor! I really only use NetBeans , notepad++ and vi for everything and never had such problems – DanFromGermany Jan 24 '14 at 18:26
@DavidHoude It's making me wait a few more minutes (stupid timers!), I haven't forgotten! – Uncle Nerdicus Jan 24 '14 at 18:27
@DanFromGermany I'll keep note of that. Thanks man! :) – Uncle Nerdicus Jan 24 '14 at 18:27
@UncleNerdicus if you ever encounter ^M at your line endings or similiar, it's because of wrong line ending (\r\n chars) dos/unix/mac (there are tools: dos2unix etc), just in case ;D – DanFromGermany Jan 24 '14 at 18:30

You missed VirtualHost setting.

NG: DocumentRoot "/Library/WebServer/Documents/dev2"

OK: DocumentRoot /Library/WebServer/Documents/dev2

share|improve this answer

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.