I followed the instructions at this question but I am getting 404s when trying to access http://localhost/~user
.
The httpd error log shows the following message:
[Tue Jul 23 20:34:34 2013] [error] [client ::1] File does not exist: /Library/Server/Web/Data/Sites/Default/~user
The userdir module is being loaded, and the Include /private/etc/apache2/extra/httpd-userdir.conf
line is not commented out.
If I put a deliberate error in /etc/apache2/users/user.conf, apachectl configtest
will fail, so it is reading this file — which means /etc/apache2/extra/httpd-userdir.conf is fine as well.
Without the error, user.conf reads
<Directory "/Users/user/Sites/">
Options Indexes MultiViews FollowSymlinks
AllowOverride AuthConfig Limit
Order allow,deny
Allow from all
</Directory>
and httpd-userdif.conf reads
# Settings for user home directories
#
# Required module: mod_userdir
#
# UserDir: The name of the directory that is appended onto a user's home
# directory if a ~user request is received. Note that you must also set
# the default access control for these directories, as in the example below.
#
UserDir Sites
#
# Users might not be in /Users/*/Sites, so use user-specific config files.
#
Include /private/etc/apache2/users/*.conf
<IfModule bonjour_module>
RegisterUserSite customized-users
</IfModule>
Does anybody have any idea what could be going wrong here? (And also, why Apple didn't just leave well alone and have this working by default, like it did in earlier versions of OS X? :)
Edit: Interestingly, if I change Userdir Sites
to Userdir /Users/*/STUFF
I still get the same error message, with the original path — so Apache seems to be ignoring this line entirely. Sometimes I think we'd be better off with a slide rule.
user
exist on your system? And did you restart Apache after doing the config changes?user
here). I ransudo apachectl restart
each time. Do I need to restart throughlaunchctl
on OS X Server, perhaps?/Users/user/Sites
on the local disk? PS: To restart I usually runlaunchctl unload /System/Library/LaunchDaemons/org.apache.httpd.plist; launchctl load /System/Library/LaunchDaemons/org.apache.httpd.plist