I'd like to run a script that deletes everything from ou=People (~ 5000 users).
The problem is that I first run a search and the result size is limited by the server.
Increasing thiis limit would surely work but I don't find it very elegant. Do you see another solution ?
Thanks in advance,
--
Mikael Kermorgant
PS : My script does the following :
retrieveAttributes = [ "entrydn" ]
searchFilter = "(uid=*)"
ldap_result_id = l.search(baseDN, searchScope, searchFilter, retrieveAttributes)
while 1:
result_type, result_data = l.result(ldap_result_id, 0)
if (result_data == []):
break
else:
if result_type == ldap.RES_SEARCH_ENTRY:
print result_data[0][1]['entrydn'][0] + ' deleted'
l.delete_s(result_data[0][1]['entrydn'][0])
-- Fedora-directory-users mailing list Fedora-directory-users@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/fedora-directory-users