Windows Vista Tips

Windows Vista Tips > Newsgroups > Windows Server > Active Directory > Re: Frequent ADsOpenObject() calls result in 0x8007203A

Reply
Thread Tools Display Modes

Re: Frequent ADsOpenObject() calls result in 0x8007203A

 
 
Chris Dent
Guest
Posts: n/a

 
      04-27-2010

Hi Martin,

I suspect you're saturating the network connections (ports) available to
RPC. The pause you're adding would appear to give it time to clear up
completed connections.

I realise you've not using ADMT, however the action you're attempting to
perform is similar:

http://support.microsoft.com/?id=836429

Do you really need to write to all 5000 objects?

Chris

Martin wrote:
> Hi guys,
>
> I'm trying to open some 5000 computer objects in a loop. Anyway, at
> some point (say on 1500-ish iteration of the loop) ADsOpenObject()
> returns 0x8007203A (The server is not operational). But when I put a
> delay before each call (say, Sleep(20)), nothing similar happens. Any
> ideas why frequent calls to ADsOpenObject() may result in 0x8007203A?
>
>
> Martin
>


--
Blog: http://www.indented.co.uk
DnsShell: http://code.msdn.microsoft.com/dnsshell
 
Reply With Quote
 
 
 
 
Chris Dent
Guest
Posts: n/a

 
      04-27-2010

Martin wrote:
> On Apr 27, 1:36 pm, Chris Dent <ch...@noreply.null> wrote:
>
>> Hi Martin,
>>
>> I suspect you're saturating the network connections (ports) available to
>> RPC. The pause you're adding would appear to give it time to clear up
>> completed connections.
>>
>> I realise you've not using ADMT, however the action you're attempting to
>> perform is similar:
>>
>> http://support.microsoft.com/?id=836429
>>
>> Do you really need to write to all 5000 objects?
>>
>> Chris
>>
>> Martin wrote:
>>
>>> Hi guys,
>>>
>>> I'm trying to open some 5000 computer objects in a loop. Anyway, at
>>> some point (say on 1500-ish iteration of the loop) ADsOpenObject()
>>> returns 0x8007203A (The server is not operational). But when I put a
>>> delay before each call (say, Sleep(20)), nothing similar happens. Any
>>> ideas why frequent calls to ADsOpenObject() may result in 0x8007203A?
>>>
>>> Martin
>>>

>> --
>> Blog:http://www.indented.co.uk
>> DnsShell:http://code.msdn.microsoft.com/dnsshell
>>

>
> Hi Chris,
>
> Yes, this is it, thanks a lot! Unfortunately, calling ADsOpenObject()
> for each computer object is set by design, and I can't change much
> here. On the other hand, is there even a way to somehow manage ports
> allocated for RPC manually (I mean programmatically)?
>
>
> Martin
>

Not really for two reasons.

1. ADsOpenObject is handling the client-side of connection negotiation
2. The server-side, the service you're talking to, allocates the port

Either you need a different method, or you need to batch / stagger the
calls, or you need to increase the number of ports available to you
using the method described in the KB article above. If you're writing
from the client-side for a generic environment then the first two are
most appropriate, but it depends a lot on how you're executing the code.

I'm afraid that isn't the most useful response in the world.

Chris

--
Blog: http://www.indented.co.uk
DnsShell: http://code.msdn.microsoft.com/dnsshell
 
Reply With Quote
 
Chris Dent
Guest
Posts: n/a

 
      04-27-2010


Martin wrote:
> On Apr 27, 3:18 pm, Chris Dent <ch...@noreply.null> wrote:
>
>> Martin wrote:
>>
>>> On Apr 27, 1:36 pm, Chris Dent <ch...@noreply.null> wrote:
>>>
>>>> Hi Martin,
>>>>
>>>> I suspect you're saturating the network connections (ports) available to
>>>> RPC. The pause you're adding would appear to give it time to clear up
>>>> completed connections.
>>>>
>>>> I realise you've not using ADMT, however the action you're attempting to
>>>> perform is similar:
>>>>
>>>> http://support.microsoft.com/?id=836429
>>>>
>>>> Do you really need to write to all 5000 objects?
>>>>
>>>> Chris
>>>>
>>>> Martin wrote:
>>>>
>>>>> Hi guys,
>>>>>
>>>>> I'm trying to open some 5000 computer objects in a loop. Anyway, at
>>>>> some point (say on 1500-ish iteration of the loop) ADsOpenObject()
>>>>> returns 0x8007203A (The server is not operational). But when I put a
>>>>> delay before each call (say, Sleep(20)), nothing similar happens. Any
>>>>> ideas why frequent calls to ADsOpenObject() may result in 0x8007203A?
>>>>>
>>>>> Martin
>>>>>
>>>> --
>>>> Blog:http://www.indented.co.uk
>>>> DnsShell:http://code.msdn.microsoft.com/dnsshell
>>>>
>>> Hi Chris,
>>>
>>> Yes, this is it, thanks a lot! Unfortunately, calling ADsOpenObject()
>>> for each computer object is set by design, and I can't change much
>>> here. On the other hand, is there even a way to somehow manage ports
>>> allocated for RPC manually (I mean programmatically)?
>>>
>>> Martin
>>>

>> Not really for two reasons.
>>
>> 1. ADsOpenObject is handling the client-side of connection negotiation
>> 2. The server-side, the service you're talking to, allocates the port
>>
>> Either you need a different method, or you need to batch / stagger the
>> calls, or you need to increase the number of ports available to you
>> using the method described in the KB article above. If you're writing
>> from the client-side for a generic environment then the first two are
>> most appropriate, but it depends a lot on how you're executing the code.
>>
>> I'm afraid that isn't the most useful response in the world.
>>
>> Chris
>>
>> --
>> Blog:http://www.indented.co.uk
>> DnsShell:http://code.msdn.microsoft.com/dnsshell
>>

>
> Okay, I'll try to work it out. Thanks again!
>
> Martin
>


Good luck

--
Blog: http://www.indented.co.uk
DnsShell: http://code.msdn.microsoft.com/dnsshell
 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
sbs 2003 network slow why? john Windows Small Business Server 9 04-03-2010 11:10 PM
Error code 0x80071A30 Anjomaba Windows Update 8 11-13-2009 10:59 PM
Windows Media Player (11) is not installed properly. Reinstall... Godenjoyer Windows Media Player 19 10-28-2009 10:50 PM



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59