LDAP Enrollment with MS Active Directory - Where is the current documentation?

LDAP Enrollment with MS Active Directory - Where is the current documentation?

by John Lohr -
Number of replies: 5

I've scoured the forums looking for relevant information to help me get LDAP Enrollment working in a modern version of Moodle (testing with 2.02) with Active Directory, but all I can find it outdated information and most of it is not MS AD specific.  Where can I find current information?  The Moodle Docs page is from 2007 and some of it does not seem relevant to newer versions of Moodle.

I have LDAP Authentication working and I think I have all the enrollment settings correct, but no matter what variation I try, it doesn't seem to work.  Here are my settings:

Moodle LDAP Authentication Settings:

User lookup settings

User type MS ActiveDirectory
Contexts OU=moodleusers,DC=TestDomain,DC=local
Search subcontexts Yes
Dereference aliases No
User attribute samaccountname
Member attribute
Member attribute uses dn
Object class *

Enable user creation

Create users externally NoYes
Context for new users

Course creator

Creators OU=Course Creators,OU=moodleEnrollement,DC=TestDomain,DC=local

Cron synchronization script

Removed ext user Suspend internal

NTLM SSO

Enable No
Subnet
MS IE fast path? No
Authentication type NTLM

Data mapping

First name
givenName

Surname
sn
Email address
mail
City/town
l
Country
c
Language
Description
Web page
ID number
samaccountname
Institution
Department
o
Phone 1
telephoneNumber
Phone 2
Address
streetAddress

 

Moodle LDAP Enrollment Settings:

Role mapping

Roles OU=Managers,OU=moodleEnrollement,DC=TestDomain,DC=local member
Course creator OU=Course Creators,OU=moodleEnrollement,DC=TestDomain,DC=local member
Teacher OU=Teachers,OU=moodleEnrollement,DC=TestDomain,DC=local member
Non-editing teacher
Student OU=Students,OU=moodleEnrollement,DC=TestDomain,DC=local member
Guest
Authenticated user
Authenticated user on frontpage
LDAP contexts
LDAP member attribute

Search subcontexts: Yes

Member attribute uses dn: Yes

Contexts:  OU=moodleusers,DC=TestDomain,DC=local
Search subcontexts: Yes
User type: MS ActiveDirectory
Dereference aliases: No

ID number attribute: samaccountname

Course enrolment settings

Object class: (objectClass=group)
ID number: cn

Short name: sn

Full name: givenName

Summary: Comment

Ignore hidden courses: No
External unenrol action: Unenrol user from course

Automatic course creation settings

Auto create: Yes
Category: Miscellaneous
Template: (Empty)

Nested groups settings

Nested groups: No
'Member of' attribute: (Empty)
Average of ratings: -
In reply to John Lohr

Re: LDAP Enrollment with MS Active Directory - Where is the current documentation?

by John Lohr -

Help please?

In reply to John Lohr

Re: LDAP Enrollment with MS Active Directory - Where is the current documentation?

by Tobias Bäumlin -

Hi

The only thing that comes to mind when I check the config you're showing:

What is the value you set in the 'LDAP member attribute' column next to the roles and LDAP Contexts and are you sure it uses fully qualified distinguished names (dn)?

 

In reply to John Lohr

Re: LDAP Enrollment with MS Active Directory - Where is the current documentation?

by Iñaki Arenaza -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
The following images (sorry to host them outside Moodle.org, but Moodle forums don't let attach more than one file, and their size is over the limit) show the settings I use with AD on Windows 2003 Server (moodle server runs on a Debian Linux box)

This link points to the LDAP authentication settings: http://img87.imageshack.us/i/ldapauthsettings.png/ and this link points to the LDAP enrolment settings: http://img600.imageshack.us/i/ldapenrolsettings.png/

Click on the image thumbs to make them bigger.
Hope that helps.

Saludos.
Iñaki.
In reply to Iñaki Arenaza

Re: LDAP Enrollment with MS Active Directory - Where is the current documentation?

by John Lohr -

Thanks for sharing that.

I actually abandoned 2.0 for now (other reasons) and installed version 1.9.12 on a test box to try to get LDAP enrollment working.  I did manage to get a little further (courses are now created when I run the ..\enrol\ldap\enrol_ldap_sync.php script).

My problem is that I get errors that it could not find the users to enrol:

D:\server\moodle\enrol\ldap>php enrol_ldap_sync.php

== Synching Course01
Could not find user CN=Moodle TestUser,OU=moodleUsers,DC=TestDomain,DC=local, skipping
== Synching Course02
Could not find user CN=Moodle TestUser,OU=moodleUsers,DC=TestDomain,DC=local, skipping

In reply to John Lohr

Re: LDAP Enrollment with MS Active Directory - Where is the current documentation?

by John Lohr -

Any suggestions?