Re: NetGroupGetUsers() occasional failures



Dave Lowther wrote:
> My code has the domain controller name in the 1st param and works fine
> except on my PC where it fails once every 12 mins 20 secs. I'm
> calling the API once every 10 seconds, so it works 73 times, then
> fails once, then works 73 times etc.

Even if the code worked perfectly this kind of polling is a bad idea. Do you
really expect groups to change so often? In any realistic organization
polling every few hours should be more than enough. Enumerating groups is an
expensive operation (especially on large domains) both in terms of server
CPU time and in network traffic. Doing it very often (and I guess you will
also do it from multiple machines) puts unnecessary strain on your DC and
network.

Also remember that all Net APIs are remote RPC calls. As such you must
*expect* them to fall occasionally. I am not saying that the symptoms you
are seeing are not a result of some faulty software on your box but even if
so it doesn't really matter. Any time you use Net API you should be prepared
to get an error because of congested network, busy server etc. In such case
your only choice is to retry a reasonable amount of times.


--
Eugene
http://www.gershnik.com


.



Relevant Pages

  • RE: Strange Irregular DNS/Networking Problems
    ... My network is not a complicated set up and only has one domain controller. ... problems with DNS resolving after changing DNS servers. ... I was already using the server for DHCP. ...
    (microsoft.public.windows.server.dns)
  • Re: IPSec / domain isolation: confusing MS documents
    ... workstation, he is able to attach to server ressources again, but for our ... The user right for access this computer from the network ... will not work for computer accounts unless ipsec is being used. ... securing a domain controller. ...
    (microsoft.public.windows.server.security)
  • RE: Strange Irregular DNS/Networking Problems
    ... Disable offloading in the network adapter properties ... After doing this on the server and the client it seems to have fixed ... Tested with just one client and the domain controller on the ... "Meinolf Weber" wrote: ...
    (microsoft.public.windows.server.dns)
  • RE: Strange Irregular DNS/Networking Problems
    ... "Meinolf Weber" wrote: ... Disable offloading in the network adapter properties ... worse than vista was because chimney offloading was on by default ... Tested with just one client and the domain controller on the ...
    (microsoft.public.windows.server.dns)
  • Re: This machine is not working properly as a DC.
    ... this is maybe a little telltale 'IntelPRO/1000 MT Network Connection ... phantom, try running the 'Change Server IP address' wiz, move the server to ... event id 2008 source ntds replication, category ds rpc client, user NT ... computer name of the source domain controller. ...
    (microsoft.public.windows.server.sbs)