diff -r a04ea5e7c15b -r 36f66a013838 check_ldap_repl.pl --- a/check_ldap_repl.pl Thu Nov 29 12:12:29 2012 +0100 +++ b/check_ldap_repl.pl Thu Nov 29 13:52:00 2012 +0100 @@ -17,12 +17,6 @@ # # Christian Arnold -# packages: libnet-ldap-perl -# packages: libio-prompt-perl -# packages: libio-socket-ssl-perl -# packages: libconfig-inifiles-perl -# packages: perl-doc (optional - for man page) - use strict; use File::Basename; use Getopt::Long; @@ -49,7 +43,7 @@ my $ME = basename $0; my $NAME = "LDAPREPL"; -my $VERSION = "0.1"; +my $VERSION = "0.2"; my %opt = ( init => 0, @@ -157,6 +151,9 @@ if ( ($type eq "init") || ($type eq "delete") ) { $binddn = prompt('BindDN: '); $password = prompt('Password: ', -e => '*'); + if (-r $opt{file}) { + (undef, undef, $master, undef, undef) = read_config(); + } } else { if ($opt{binddn} && $opt{password}) { $binddn = $opt{binddn}; @@ -309,13 +306,13 @@ =item B<-i>|B<--init> -Add the check object cn=replcheck,I to the master server if not existis. See also the B<--cn> option. +Add the check object cn=replcheck,I to the master server if not exists. See also the B<--cn> option. You will ask for an B and B, if not given B<--binddn> and B<--password> options. Your B must have write permission to the ldap master server. =item B<-d>|B<--delete> -Delete the check object from the ldap master server if existis. See also the B<--cn> option. +Delete the check object from the ldap master server if exists. See also the B<--cn> option. You will ask for an B and B, if not given B<--binddn> and B<--password> options. Your B must have write permission to the ldap master server. @@ -387,7 +384,7 @@ =head1 VERSION -This man page is current for version 0.1 of B. +This man page is current for version 0.2 of B. =head1 AUTHOR