ldifdiff.pl -- Generates LDIF change diff between two sorted LDIF files.
ldifdiff.pl takes as input two sorted LDIF files, source and target, and generates on standard output the LDIF changes needed to transform the target into the source.
ldifdiff.pl -k|--keyattr keyattr [-a|--sourceattrs attr1,attr2,...] [-c|--ciscmp attr1,...] [-n|--numcmp attr1,...] [--dnattrs attr1,...] [--sharedattrs attr1,...] sourcefile targetfile
Specifies the key attribute to use when comparing source and target entries. Entries in both LDIF files must be sorted by this attribute for comparisons to be meaningful. ldifsort.pl can be used to sort LDIF files by a given attribute.
(Optional) Specifies a list of attributes to consider when comparing source and target entries. By default, all attributes are considered.
(Optional) Compare values of the specified attributes case-insensitively. The default set is: mail manager member objectclass owner uid uniqueMember
(Optional) Compare values of the specified attributes numerically. The default set is: employeeNumber
(Optional) Specifies a list of attributes to be treated as DNs when being compared. The default set is: manager member owner uniqueMember
(Optional) Specifies a list of attribues to be treated as "shared" attributes, where the source may not be a sole authoritative source. When modifying these attributes, separate "delete" and "add" LDIF changes are generated, instead of a single "replace" change. The default set is objectClass.
Specifies the source LDIF file.
Specifies the target LDIF file.
Kartik Subbarao <subbarao@computer.org>
To install Net::LDAP, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Net::LDAP
CPAN shell
perl -MCPAN -e shell install Net::LDAP
For more information on module installation, please visit the detailed CPAN module installation guide.