I've been working on the same issue for days now and I cannot for the life of me fathom out where I am falling down. I have searched all the forums for people who may have had the same issue to no avail.
We're running Windows 2003 with a MSSQL backend. Everything is working fine in Moodle, authentication is working without problem, etc etc. The problem is just with auto course creation and enrolment.
To debug the issue we've been running the enrol/ldap/enrol_ldap_sync.php file and this is what we find: the courses are created...excellent...but the enrolment of the users to those courses is failing. Further to that it seems that in searching for the users to add the the group it is actually searching for the group itself rather than the user (see below):
== Synching maths101 Could not find user maths101(stud), skipping == Synching maths101 Could not find user CN=maths101,OU=Staff,OU=NCSUsers,DC=newent,DC=school, skipping == Synching maths101 Could not find user CN=maths101,OU=Students,OU=NCSUsers,DC=newent,DC=school, skipping
I've been over and over the settings but everything is as it should be as far as I can see. Please, can anyone help or give a suggestion?