LDAP Enrollment Module

LDAP Enrollment Module

- Tom McClain の投稿
返信数: 1
Hello,
We are working on an integration of Moodle 1.8 with a Sun Directory server.
Sun Dir (box 1) <--> LAMP (box 2, RHEL3)
We are able to get the authentication piece working where running the enrol_ldap_sync.php the following error is thrown
Could not find user

Worried that it was something flaky with the Directory Server, a test install was set up on a dev box for proof of concept. Efforts are focused on getting the dev box running:

Debian 4.0
PHP 5
OpenLDAP 2.3.30-5
Apache 2

We were able to import enrolLDAPmoodle.ldif into the OpenLDAP server successfully. LDAP component seems to working properly

After configuring the server, attempted to run the sync command. The following error was displayed:
--
== Synching Math101
Could not find user teachera, skipping
== Synching Eng201
Could not find user teachera, skipping
Could not find user teacherb, skipping
== Synching Math101
Could not find user studentd, skipping
Could not find user studente, skipping
== Synching Eng201
Could not find user studente, skipping
Could not find user studentf, skipping
--
I have "studied" the following posts:
http://moodle.org/mod/forum/discuss.php?d=31761
http://moodle.org/mod/forum/discuss.php?d=39549
http://moodle.org/mod/forum/discuss.php?d=41829
to no avail and approaching wits end.

Configs for the dev box
Authentication
Host: ldap://localhost/
Version: 3
LDAP encoding: utf-8
Hide Passwords: no
Distinguished Name: cn=admin,dc=moodle,dc=tiu11,dc=org
Password: *****
User type: posixAccount(rfc2307)
Context: ou=People,dc=moodle,dc=tiu11,dc=org
Search subcontext: Yes
Dereference Aliases: Yes
Force change password: no
Use standard Change Password Page: no
Password format: SSHA-1
..
DATA MAPPINGS
First name: givenName
Surname: sn
Email Address: mail
...
ID Number: uid

Courses - Enrolments

enrol_ldap_host_url: ldap://localhost/
enrol_ldap_version: 3
enrol_ldap_bind_dn: cn=admin,dc=moodle,dc=tiu11,dc=org
ldap_bind_pw: *****
ldap_search_sub: Yes
Teacher:
LDAP Contexts: ou=TeacherEnrollment,dc=moodle,dc=tiu11,dc=org
LDAP member attribute: memberUid

Student:
LDAP Context:
ou=StudentEnrollment,dc=moodle,dc=tiu11,dc=org
LDAP member attribute: memberUid
enrol_ldap_objectClass: posixGroup
enrol_ldap_course_idnumber: cn
enrol_ldap_course_shortname: cn
enrol_ldap_course_fullname: cn
enrol_ldap_course_summary:
enrol_ldap_autocreate: yes
enrol_ldap_category: Miscellaneous

I've attached a LDIF of the current set up.
What am I missing?
Thanks for any assistance.

Tom McClain への返信

Re: LDAP Enrollment Module

- Tom McClain の投稿
I found my issue. I continued to research the discussion threads and found the issue.
Solution:
In the thread

by Michael Johnson - Saturday, 28 January 2006, 02:53 AM

A reference is made to the following scripts:

"php /var/www/moodle/auth/ldap/auth_ldap_sync_users.php && php /var/www/moodle/enrol/ldap/enrol_ldap_sync.php"

In addition, providing the default Moodle user with "CREATE TEMPORARY TABLE" permissions

So...
I granted the permission to the Moodle user
Ran the scripts and voila...

Thanks to anyone who read the post and I hope having this all together will help someone in the future..