Hi all,
I'm running a webserver on Fedora 10 with no problem for the default server.
Recently, I wanted to add some users to Fedora, and allow them to upload their own files.
I checked many times the following:
- Userdir has 711 permission
- public_html directory ( and its content) is set to 755 permission
- modified httpd.conf by removing UserDir disable, and uncommented UserDir public_html
- Uncommented the <Directory>...for alllowing all users to have accces to /~user directory.
- SElinux is disabled (In fact, uninstalled)
- There is no specific info in error_log other then 'File does not exist....'.
- Nothing in the messages log file either.
Any suggestions?
Thanks,
Faruk

Are there any files in the public_html directory? Apache will throw a 403 or 404 at you if there's not a valid index file (typically index.php or index.html, although this can be configured).

If you do have content in the public_html directory, I know you mentioned you already that you've set permissions and enabled the userdir above but just to double check can you attach/pastebin your httpd.conf here (be sure to remove any sensitive information first)? As well, you can ensure that the permissions are correct by running:

Code:

ls -ld ~
ls -ld ~/public_html
ls -l ~/public_html/index.html

The permissions should be 711, 755 and 644 respectively.

Edit: Also, do have you made any extensive configuration changes to httpd.conf or added a custom file to /etc/httpd/conf.d? One of the config rules could be overriding or changing the behavior of another rule.

Are there any files in the public_html directory? Apache will throw a 403 or 404 at you if there's not a valid index file (typically index.php or index.html, although this can be configured).

If you do have content in the public_html directory, I know you mentioned you already that you've set permissions and enabled the userdir above but just to double check can you attach/pastebin your httpd.conf here (be sure to remove any sensitive information first)? As well, you can ensure that the permissions are correct by running:

Code:

ls -ld ~
ls -ld ~/public_html
ls -l ~/public_html/index.html

The permissions should be 711, 755 and 644 respectively.

Edit: Also, do have you made any extensive configuration changes to httpd.conf or added a custom file to /etc/httpd/conf.d? One of the config rules could be overriding or changing the behavior of another rule.

- public_html is automatically created with index.htm for each user added to the server, with all permissions set.
- I have checked once again the permissions, but nothing seems wrong. Here is the permissions list:
~test/ = 711
~test/public_html=755
/public_html/index.htm 755 (changed it to 644, but no change)

I have attched the httpd.conf file in use as httpd.txt.
Besides, I did not configure anything but httpd.conf only, so I do not use a second conf file for apache, and finallly: I had uninstalled SElinux completely.

UserDir enabled all
# To enable requests to /~user/ to serve the user's public_html
# directory, remove the "UserDir disabled" line above, and uncomment
# the following line instead:
#
UserDir public_html

It should read:

Code:

#UserDir disabled
# To enable requests to /~user/ to serve the user's public_html
# directory, remove the "UserDir disabled" line above, and uncomment
# the following line instead:
#
UserDir public_html

UserDir enabled all
# To enable requests to /~user/ to serve the user's public_html
# directory, remove the "UserDir disabled" line above, and uncomment
# the following line instead:
#
UserDir public_html

It should read:

Code:

#UserDir disabled
# To enable requests to /~user/ to serve the user's public_html
# directory, remove the "UserDir disabled" line above, and uncomment
# the following line instead:
#
UserDir public_html

I had tried to access the user pages with
- UserDir enabled all
#UserDir disabled (commented)
-or completetly removed UserDir disbaled line from the httpd.conf file.
Urfortunatetly, nothing changed. Still getting File does not exist: /var/www/html/~test.
Does running the server on a Virtual Machine create any problem for accessing Userdirs?
Any idea?

Thought I might add a note here after spending 8 hours pounding keys, checking web yadayadayada.
The information in httpd.conf appears to be replaced/overlooked when there are other .conf files in the conf.d directory, ie my httpd.conf file could be edited, changed, turned blue and there were NO changes to the results. Finaly found that the system-config-httpd.conf file in conf.d directory ALSO had the same section about user directories as the httpd.conf file. changing the values in the system-config-httpd.conf file DID yeild the results we all expect. Nice.