Excesive users from LDAP

Excesive users from LDAP

by Pedro Gago -
Number of replies: 3

Hi all,

I think I have made an error configuring LDAP with the bind_dn or the context and I have now in Moodle more users than needed. I want to revert this situation. I have changed the bind_dn and force a resync but all the users still exist in Moodle.

My question is: how can I delete this extra users? Please, consider that the correct users have information (courses done, califications, etc) and I don't want to lose it.

My Moodle version is 3.9.

Thanks in advance. 

Pedro

Average of ratings: -
In reply to Pedro Gago

Re: Excesive users from LDAP

by Pedro Gago -
Anyone can advise here?
In reply to Pedro Gago

Re: Excesive users from LDAP

by Emma Richardson -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers
You need to change the setting in ldap settings to either suspend or delete the users that are no longer being pulled from the OU. Now the bind_dn is not going to affect the number of users though unless the new bind user only has permissions to see certain users - you need to either change the context (location of ou where your users are) or create a filter to only pull members of a certain group.
In reply to Emma Richardson

Re: Excesive users from LDAP

by Pedro Gago -
Thanks Emma.
Let me explain a bit more to understand your answer:
- I had the correct users (example user1) with info attached like courses, activities, certificates, etc.
- Due to any change in LDAP binding, incorrect users (example user2) has been added to moodle. These users don't have any info in Moodle.
Nota: I have to investigate what is the difference in LDAP binding.
So, if I suspend or delete the users in order to change the context and obtain only correct users (in my case only user1), won't I lose the info of correct users? I don't want to lose this info. Can you confirm the steps you gave me?
Thanks