LDAP deleting old users / ran mass synconisation

LDAP deleting old users / ran mass synconisation

by Jarrod Morrison -
Number of replies: 1

Hello

I have a moodle 2.5.2 install linked in with active directory via ldap where it had a lot of ex students still stored in the database that are no longer in AD. So I checked under my authentication and made sure it had delete the users when they are in the external source and ran the cron.php but it didn't remove any of the accounts. After a bit of googling and not getting anywhere people were talking about mass synchronisation and I found the moodle/auth/ldap/cli/sync_users.php and thought this is what people meant. After running this it has brought in every AD computer account amongst all the other ad accounts which isn't what I wanted. Would this have also buggered all the security and course memberships where I will have to recover from a backup now ? Am I misunderstanding how moodle should deal with the deleted accounts from AD ?

Average of ratings: -
In reply to Jarrod Morrison

Re: LDAP deleting old users / ran mass synconisation

by Ken Task -
Picture of Particularly helpful Moodlers

What do you have set for Context?   If you have the top level of the domain ... ie, DC's then you'll get it all - including all the junk/test accounts, etc..

If you have the context set for OU=Student,OU=Some Campus,DC=somenetwork,DC=net and OU=Teacher,OU=Some Campus,DC=somenetwork,DC=net then you should get ONLY Teachers and Students.

Kinda depends upon how LDAP is organized.

There some comments in sync_users.php which may/may not help ya.

Truth in attempting to assist ... am not a LDAP/AD server administrator.

'spirit of sharing', Ken