Ok, I guess I'm not good enough XP-wise to edit my main post? Well, here's a new twist to the whole story. I logged in via ssh from my parent's home, ran the program, and it worked fine. I added the loop back in, changed back to the $ldap->add() style of code, and it successfully added about 50 entries.

When I got back to my office this morning, it doesn't work. Is there something in my RH8 environment that might be knocking it out of shape? UTF-8 ?

here's what the debug=>8 out yielded...

Net::LDAP=HASH(0x8d9c378) sending: Net::LDAP=HASH(0x8d9c378) received: 0000 12: SEQUENCE { 0002 1: INTEGER = 1 0005 7: [APPLICATION 1] { 0007 1: ENUM = 0 000A 0: STRING = '' 000C 0: STRING = '' 000E : } 000E : } Net::LDAP=HASH(0x8d9c378) sending:
And it just hangs right there. My current code base (just the ldap part):
use Net::LDAP; use Net::LDAP::Entry; my $ldap = Net::LDAP->new('localhost',debug=>8); my $bind_msg = $ldap->bind( dn => 'cn=Manager, dc=osprey,dc=net', password => 'secret' ); if ( my $bind_code = $bind_msg->code ) { die "Cannot bind:", $bind_msg->error, " (Code: $bind_code)"; } foreach my $username (sort keys %petra) { my $dn = "uid=${username}_osprey_net, ou=users, ispmanDomain=osprey.n +et, dc=osprey,dc=net"; my $ref = $petra{$username}; $result = $ldap->add( dn=> $dn,attr => [@$ref] ); $result->code && warn "$dn" ."failed to add entry: ", $result->error ; }

In reply to Update: Re: perl-LDAP process hangs by Notromda
in thread perl-LDAP process hangs by Notromda

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.