>>> Howard Chu <[email protected]> schrieb am 17.01.2023 um 17:40 in Nachricht
<[email protected]>:
> Ulrich Windl wrote:
>> Hi!
>> 
>> I'm working on a program that "mangles" existing LDIF files so that the LDAP 
> server accepts them.
>> So say 75% passed, 25% had errors (need additional fixes).
>> 
>> I'm using ldapadd with "-c" (continue) and "-S skipped.ldif" (skipped 
> entries) to add the input LDIF.
>> 
>> The idea was to iterate over skipped.ldif until the file is empty, i.e.: 
> make skipped.ldif the new input file for the next run of ldapadd.
>> However "skipped.ldif" also contains entries that were skipped, because they 
> had been imported (successfully) before ("ldap_add: Already exists (68)").
>> 
>> Is there an easy way to extract only those entries that were not added?
>> 
>> Of course I could write a program that implements that logic, talking to the 
> LDAP server directly, but if avoidable I'd save the time to write such a 
> program.
> 
> Don't use -c, fix errors as they appear, and use -j to resume.

Thanks, unfortunately my versions of ldapadd don't have that option yet.

> 
> 
> -- 
>   -- Howard Chu
>   CTO, Symas Corp.           http://www.symas.com 
>   Director, Highland Sun     http://highlandsun.com/hyc/ 
>   Chief Architect, OpenLDAP  http://www.openldap.org/project/ 



Reply via email to