From: Brad D. <brad@DiggsFamily.net> - 2003-03-18 21:08:20
|
I have written a simple script to load a bunch of users from an input file (comma separated data) into my directory service. This perl script uses Net::LDAP to add the entries. However, the load hangs on adding the first entry. From the server side, I never see an add request. So, it seems like the perl-ldap code is hanging for some reason. Have you seen this before? Here is an excerpt from the perl script: # # Establish LDAP connection to directory service # $ldap = new Net::LDAP ($opt_h, port=> $opt_p); # # will bind as specific user if specified else will be binded anonymously # $ldap->bind( $opt_D, password => $opt_w) || die "failed to bind as $opt_D"; ... # # Add each entry to the directory # $mycn = "$first_name $last_name"; $dn = "cn=$mycn, $base_suffix"; $result = $ldap->add( $dn, attrs => [ 'cn' => $mycn, 'sn' => $last_name, 'objectclass' => [ 'top', 'person', 'organizationalPerson', 'inetOrgPerson' ] ] ); Environment: OS: Red Hat Linux v8.0 Kernel: 2.4.18-14 Perl Version: v5.8.0 built for i386-linux-thread-multi perl-ldap version: perl-ldap-0.2701 Module Versions: Authen-SASL-2.03 Convert-ASN1-0.16 Net_SSLeay.pm-1.22 IO-Socket-SSL-0.92 Results from perl Makefile.PL Checking for OPTIONAL modules URI ..........................ok URI::ldap ....................ok Digest::MD5 ..................ok IO::Socket::SSL ..............ok XML::Parser ..................ok MIME::Base64 .................ok Authen::SASL .................ok Thanks in advance, Brad |