Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - Server
User Name
Linux - Server This forum is for the discussion of Linux Software used in a server related context.


  Search this Thread
Old 07-03-2009, 08:22 AM   #1
Registered: Oct 2004
Location: Athens, Greece
Distribution: Suse Linux
Posts: 98

Rep: Reputation: 16
Apache 2.2 and LDAP Based home directories

Dear all,
I have a RHEL 5 Web Server based on Apache 2.2
I need to offer the user's web pages in the web via the classic form

All users are located in an openLDAP server. The users are not locally installed. I cannot use the classic approach of UserDir=/home/*/public_html, because:
  • User directories are in the form /home_usr/department/1/2/3/username
  • 1,2 are the departments' subdepartments
    [3] is the 1st letter of user's last name.
So, for Sales - Wholesales - East dpt user jim, his homedirectory is:
and his html pages should be at
So, the UserDir=/home/*/public_html is not a usable approach by me.

I tries the mod_userdir_ldap from, but it's not working! It does not even go to openLDAP Server.

Some of my the httpd.conf lines, are:
LoadModule actions_module modules/
LoadModule include_module modules/
LoadModule authn_alias_module modules/
LoadModule vhost_alias_module modules/
LoadModule alias_module modules/
LoadModule rewrite_module modules/
LoadModule userdir_module modules/
LoadModule ldap_userdir_module modules/
LoadModule auth_basic_module modules/
LoadModule auth_digest_module modules/
LoadModule authz_host_module modules/
LoadModule mime_magic_module modules/
LoadModule mime_module modules/
LoadModule log_config_module modules/
LoadModule dir_module modules/
LoadModule setenvif_module modules/
LoadModule autoindex_module modules/
LoadModule negotiation_module modules/
LoadModule env_module modules/

<VirtualHost _default_:80>
        DirectoryIndex index.php index.html index.htm
        LogLevel debug
        HostNameLookups Off
        DocumentRoot /nfs/web/
        ErrorLog logs/users_pages-error.log
        CustomLog logs/users_pages-access.log common
        ServerSignature Off

        LDAPUserDir "www"
        LDAPUserDirDNInfo cn=www,ou=read,ou=groups,ou=ldap,ou=config,dc=example,dc=com ldapuserpass
        LDAPUserDirBaseDN dc=example,dc=com
        LDAPUserDirSearchScope subtree
        LDAPUserDirUseTLS off
        LDAPUserDirCacheTimeout 300
When I try the I have the following error:
[Fri Jul 03 15:40:46 2009] [error] [client] File does not exist: /nfs/web/~jim
As far as I understand, Apache does not translate the "~" as an attempt to find the user's in LDAP! To support this, when the URL: (my home page, on the local disk not on the LDAP), returned the correct index.html page!
So, my questions are:
1. Can I enable a more detailed log?
2. What do I do wrong?

Thank you in advance,


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Apache redirect based on LDAP authentication starmonche Linux - Server 3 03-21-2008 10:42 AM
Apache Root/Home Directory and setting up FTP for home directories? Mankind75 Linux - Newbie 6 07-23-2006 02:37 PM
Samba PDC+LDAP and home directories on different servers Neruocomp Linux - Networking 0 07-13-2006 01:56 PM
OpenLDAP, Apache, Home directories paul_mat Linux - Networking 1 03-30-2006 12:20 AM
apache login to home directories paul_mat Linux - Networking 1 04-05-2005 02:29 AM > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 08:04 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration