LDAP Moodle 2.1

LDAP Moodle 2.1

by Kris Edwards -
Number of replies: 3

Hello All,


Yes I know this is an old version.  But I am having issues syncing LDAP to moodle.

I run E:\wamp\bin\php\php5.3.9\php.exe -d memory_limit=512M -d log_errors=1 -d error_reporting=E_ALL -d display_errors=0 -d html_errors=0 -d error_log=E:\scripts\syncfile-errors.log -f E:\wamp\www\moodle2015\auth\ldap\cli\sync_users.php > E:\scripts\MoodleUserSync.log

And only thing that outputs is "Connecting to LDAP server..."

It does not load any users.  Testing I used my domain account to login and it worked.  What could cause it not to insert any users when running the sync?

Right now I have DN pointing to our root domain, we are a multi domain campus.  I am also currently only pointing to the employee domain.  


Average of ratings: -
In reply to Kris Edwards

Re: LDAP Moodle 2.1

by Kris Edwards -

Iguess it helps turning all developer logging...

[14-Apr-2015 04:38:21 UTC] PHP Fatal error:  Call to undefined function ldap_connect() in E:\wamp\www\moodle2015\lib\ldaplib.php on line 177

[14-Apr-2015 04:38:21 UTC] PHP Stack trace:

[14-Apr-2015 04:38:21 UTC] PHP   1. {main}() E:\wamp\www\moodle2015\auth\ldap\cli\sync_users.php:0

[14-Apr-2015 04:38:21 UTC] PHP   2. auth_plugin_ldap->sync_users() E:\wamp\www\moodle2015\auth\ldap\cli\sync_users.php:65

[14-Apr-2015 04:38:21 UTC] PHP   3. auth_plugin_ldap->ldap_connect() E:\wamp\www\moodle2015\auth\ldap\auth.php:617

[14-Apr-2015 04:38:21 UTC] PHP   4. ldap_connect_moodle() E:\wamp\www\moodle2015\auth\ldap\auth.php:1985



In reply to Kris Edwards

Re: LDAP Moodle 2.1

by Kris Edwards -

Ok fixed that..... changed the script to 

E:\wamp\bin\php\php5.3.9\php-win.exe -c E:\WAMP\bin\apache\Apache2.2.21\bin\php.ini -d memory_limit=256M -d log_errors=1 -d error_reporting=E_ALL -d display_errors=0 -d html_errors=0 -d error_log=E:\wamp\logs\ldap_sync_user_syncfile-errors.log.log-f E:\wamp\www\moodle2015\auth\ldap\cli\sync_users.php > E:\Wamp\logs\ldap_sync_user_syncfile.log


Now... I have duplicate AD records across my AD (DONT ASK... sigh)  They are all in the same OU (users).... How can I bypass those accounts to sync across....

In reply to Kris Edwards

Re: LDAP Moodle 2.1

by Kris Edwards -

I know it isnt ideal.... they are Service accounts... We have gotten it to work before but I cant recall the fix.