By: D S user 09 Sep 2016 at 7:29 a.m. CDT

9 Responses
D S gravatar
Where are Gluu Users stored on the Server? How can I delete all Gluu users at once through Gluu?

By Michael Schwartz Account Admin 09 Sep 2016 at 8:27 a.m. CDT

Michael Schwartz gravatar
Users are stored in LDAP under `ou=people,o=(org-inum),o=gluu` There is no easy way to delete all people. You may just want to do a fresh Gluu Server install. Alternately, ldapsearch: ``` # /opt/opendj/bin/ldapsearch -h localhost -p 1636 -Z -X -D "Cn=directory manager" -j ~/.pw -b "o=gluu" "objectclass=person" dn | grep dn > people.ldif ``` _Note: put the DM password in ~/.pw and remove it when you're done with this process. _ Then write a simple python program... like `deletePeople.py` ```python #!/usr/bin/python f = open(people.ldif) lines = f.readlines() for line in lines: print line.strip() print changetype: delete print ``` Then run the program ``` # ./deletePeople.py > delPeople.ldif ``` Then load the ldif ``` # /opt/opendj/bin/ldapmodify -h localhost -p 1636 -Z -X \ -D "Cn=directory manager" -j ~/.pw -f delPeople.ldif ```

By D S user 09 Sep 2016 at 8:33 a.m. CDT

D S gravatar
There must be an ldif file or something somewhere where a list of Users are stored (ou=people)? Can't I just delete the Users out of this file and do an ldapmodify?

By Michael Schwartz Account Admin 09 Sep 2016 at 8:36 a.m. CDT

Michael Schwartz gravatar
Please see my explicit instructions above.

By D S user 09 Sep 2016 at 8:37 a.m. CDT

D S gravatar
When I look into the 'people.ldif' file, there is only the admin account listed there? When there are several other test accounts that have been created? Which file would they be stored in?

By Michael Schwartz Account Admin 09 Sep 2016 at 8:42 a.m. CDT

Michael Schwartz gravatar
They are stored in the LDAP database. Like I said, I alrady gave you perfect instructions.

By D S user 09 Sep 2016 at 8:50 a.m. CDT

D S gravatar
For directory manager, as you install opendj as a feature when installing gluu is there a default directory manager password set? is that the 'ldapPass' found in setup.properties file? Thanks

By Michael Schwartz Account Admin 09 Sep 2016 at 9:27 a.m. CDT

Michael Schwartz gravatar
yes

By D S user 12 Sep 2016 at 2:06 a.m. CDT

D S gravatar
Ok thanks, I can confirm I have run the "/opt/opendj/bin/ldapsearch -h localhost -p 1636 -Z -X -D "Cn=directory manager" -j ~/.pw -b "o=gluu" "objectclass=person" dn | grep dn > people.ldif" command, but when the people.ldif file is created - no entries are in there...?

By William Lowe user 13 Sep 2016 at 9:47 a.m. CDT

William Lowe gravatar
Tickets need to stay on topic based on the title you submitted. Please open a new ticket based on a specific issue you are facing. Do not forget to provide all relevant information, including logs, screenshots, research youve done, and steps to reproduce. Otherwise your ticket will be ignored and closed.