CHLOG2REPLOG(8C) CHLOG2REPLOG(8C)
NAME
chlog2replog - convert an X.500 DSA-style changelog to an
LDAP-style replication log
SYNOPSIS
/usr/sbin/chlog2replog -r hostname:port [-r hostname:port
...] -d dn-suffix [-o output-file] < input-file
DESCRIPTION
chlog2replog is used to convert an X.500-style changelog
to an LDAP-style replication log. It reads its standard
input and writes standard output if no -o flag is given.
If the -o flag is given, chlog2replog writes its output to
the given file, following the same advisory locking mecha
nisms respected by the slurpd program. This makes it pos
sible to use chlog2replog in a pipeline to produce input
for slurpd.
OPTIONS
-r hostname:port
This option specifies the hostname and port number
to which updates should be propagated.
chlog2replog will include one "replica: host
name:port" directive in each replication log entry
it writes out for each -r option given. You may
supply as many replica hostname:port options as you
wish.
-d dn-suffix
This option specifies an additional string to
append to converted DNs (Distinguished Names) con
verted from the changelog file. The DNs in the
changelog file will typically be partial DNs which
omit the portion of the directory tree "above" the
organizational root. For example, if your direc
tory tree is rooted at o=University of Michigan,
c=US, you will need to include the argument "-d ",
o=University of Michigan, c=US".
-o output-file
If given, this option specifies an output file to
which converted replication log entries will be
written. chlog2replog obeys the same file locking
conventions used by slurpd, so that it is possible
to use chlog2replog to "feed" changes from an X.500
DSA to slurpd. See the examples section, below, for
more information.
EXAMPLES
To read the DSA-style changelog file changlelog and write
on the standard output an LDAP-style replication log,
appending ", o=University of Michigan, c=US" to all entry
OpenLDAP 1.2 22 September 1998 1
CHLOG2REPLOG(8C) CHLOG2REPLOG(8C)
DNs, and including a replica: entry for host "ldapserver,"
port 389, give the command:
/usr/sbin/chlog2replog -d ", o=University of Michigan, c=US"
-r ldapserver:389 < changelog
To do the same, but routing the output to the file
"replog," using slurpd-compatible file-locking, give this
command:
/usr/sbin/chlog2replog -d ", o=University of Michigan, c=US"
-r ldapserver:389 -o replog < changelog
To continually read new changes from the file "changelog"
and write them to the file "replog", give this command:
tail +0f changelog | /usr/sbin/chlog2replog
-d ", o=University of Michigan, c=US"
-r ldapserver:389 -o replog < changelog
SEE ALSO
ldap(3), ldif(5), slurpd(8), slapd(8),
"The SLAPD and SLURPD Administrator's Guide"
ACKNOWLEDGEMENTS
OpenLDAP is developed and maintained by The OpenLDAP Pro
ject (http://www.openldap.org/). OpenLDAP is derived from
University of Michigan LDAP 3.3 Release.
OpenLDAP 1.2 22 September 1998 2
Man(1) output converted with
man2html