Error message using Netdiag.exe = NETDIAG.EXE - ENTRY POINT NOT FOUND

I'm running a 2003 server which is also running the DHCP/DC/DNS/A-Directory all in one due to a tight budget. When preparing to install Exchange 2003 as the first exchange server on the same machine as this machine has never had exchange on before I'm using the prep tools DCdiag.exe which has no problems the server pass's all its tests, however its a completely differant story when running Netdiag.exe. The very instant you start NetDiag you get an error box which is Titled:

NETDIAG.EXE - ENTRY POINT NOT FOUND (the actuall error is)

The procedure entry point DnsGetPrimaryDomain_UTF8 could not be located in the dynamic link library DNSAPI.dll.

Ive used depends.exe which shows a whole range of errors, but I guess I'm just not geeky enough in this area to understand what the info it is giving out, obviously something is missing but I have no idea how to correct this, which means I cannot continue wh=ith the install of Exchange 2003.

Any knowledgeable ideas would be more than welcome as Ive searched every where for a solution & come up with total blanks.

Many thanks
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

I remember, I encountered same problem. But that time I was running NetDiag.exe which was copied from other machine. But when I installed Windwos Support tools for Windwos 2003, then it started working fine.
rpartingtonAuthor Commented:
Thanks for the speedy response, but I have support tools installed from the 2003 cd NETDIAG.EXE is not included with it for some strange reason, I downloaded it from microsoft direct & installed it on the server (same error) I then installed it on a client (same error) when I run depends.exe which is included in the support tools & point depend to netdiag.exe to run it, depends.exe clearly shows the following error relating to Netdiag:

(Error: At least one module has an unresolved import due to a missing export function in an implicitly dependent module.)

The module concerned is DNSAPI.dll
Within DNSAPI.dll depends shows that the problem areas are as follows:


Its certianly a heavy duty fault which Ive got to hold my hand up & admit Ive no idea what it is & no idea where to even start looking for a fix either.
If this is a multi-homed server (2 NICs) - make sure the internal NIC is at the top of the binding order.  Also, make sure that NIC only points to for DNS.

10 Tips to Protect Your Business from Ransomware

Did you know that ransomware is the most widespread, destructive malware in the world today? It accounts for 39% of all security breaches, with ransomware gangsters projected to make $11.5B in profits from online extortion by 2019.

rpartingtonAuthor Commented:
Thanks for the response I appreciate it NETMAN66.
It is multi homed, however the internal nic is at the top of the bindings as I got caught out with that a few months ago but worked out that the internal had to be at the top of the bindings. The internal nic's DNS was not set to the loop back but Ive just set it to the as suggested but still the exact same error.
run this:

dcdiag /test:registerindns

from the server

Also run this:

netdiag /test:dns

What is the version of DNSAPI.dll on your machine?
rpartingtonAuthor Commented:
Hey thanks for all the suggestions lads, you have kept me really busy.
I for some strange reason cannot run either dcdiag or netdiag from CMD it shows that they are both not recognized as an internal or external command operable program or batch file,

even though they are both installed under Program files\Resource Kit. I can however run Dcdiag by double clicking on it & pausing the screen before the out put disappears, Net diag just gives the normal error.

The version of DNSAPI.dll is =
5.2.3790 0
Date 30/7/03
Located in System32

Again thanks lads for all your suggestions, funny enough I'm learning new things via this annoying error & getting more grey hairs with it by the hour.
Check the path statement.

At a command prompt type: PATH

If the path doesn't include reference to C:\Program Files\Resource Kit then add it in the System variable in the Properties of My Computer\Advanced.

Run the utilities again.

rpartingtonAuthor Commented:
The results of the above two Netman66 are
dcdiag /test:registerindns
...............................ROY Failed test RegisterInDNS

running: dcdiag /fix the server "ROY" passes all the the connectivity tests

netdiag /test:dns
gives the same old error message instantly.

I even ran sfc /scannow to check to see if the DNSAPI.dll file was corrupt, still no joy, yeh I know I was kind of clutching at straws with that one.
Its got me beat thats for sure

As you said DNSAPI.dll  version is 5.2.3790 0
Version for the  NetDiag.exe should be the same.

I have Windows 2003 box, on whcih DNSAPI.dll  and NetDiag.exe are same (5.2.3790). So it works fine.

Windwos 2000 Support tool  NetDiag.exe comes with version 5.0.2185. This exe does not work with DNSApi.dll  version 5.2.3790.

You can see issue with some exported funtion using Depends.

So make sure that you have NetDiag.exe (5.2.3790). This comes with Windows 2003 Support tools.
I verified the list of tools shipped with Windows 2003 support tools from

Looks like Microsoft is stopped shipping NetDiag.exe.

May be I got it from initial CDs of Windowos 2003.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
rpartingtonAuthor Commented:
Who ever you are
Where ever you are
Give your self the biggest pat on the back & have a damn good drink on me.
You guessed it,
It was the old W2K version of Netdiag also DCdiag & funnily enough even though everything was installed originally off the 2003 server CD there were quite a few other old versions in the support tools folder as well.
I had like a clown never looked in the file on the CD to check for the Netdiag tool as I noticed it was not installed in the "Support folder" & then went to the same website you went to "Microsoft Windows Server 2003 Resource Kit Tools" & saw that NetDiag was not included so I downloaded it seperately from else where from Microsoft,
THAT WAS OBVIOUSLY WHERE MY MISTAKE WAS, if only I had looked in the "" file on the CD, its obvious now, I feel like banging my head against the wall in disgust at myself, but we live and learn.

Anyone reading this in the future with the same problem, think yourself lucky that this is now here to help you as this was an easy mistake to make but it could of been costly, as I was ready to use an interim server to back everything up on, & then flatten the problem server & reinstall from scratch.

Once again Milind00
If only you knew how pleased I am this is now working,
Have a drink on me.
The 500 points are yours with pleasure.
*Your a star*

Many thanks

Roy Partington
Thanks for the Drink.  :)
I too have run into the same problem.  I have NETDiag V:5.0.2195.1340 and dnsapi.dll is V:5.2.3790.0....Now how to find the right version of NetDiag....MicroSquish...gotta love these guys!!!
I too was having the same problem, but I wanted NetDiag to check my DNS, and then I noticed
the new 2003 tool "DNSDIAG".

Just wanted to point it out.
Our problem occurred when we updated our Windows 2000 server to Windows 2003. The OS update, updated all the DLL's associated with the Support Tools. Milind00 your solution worked, reinstalling the support tools from Windows 2003 install cd.
Good to know this.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Windows Server 2003

From novice to tech pro — start learning today.