The famous 'Class not registered'

Typically, you will encounter this error with XP Pro IIS 5.1. As usual, there's way to solve it, however the root cause of this is still unknown :)

Anyway, you will get this in event log:
Event Type: Warning
Event Source: W3SVC
Event Category: None
Event ID: 36
Description:
The server failed to load application '/LM/W3SVC/1/ROOT. The error was 'Class not registered'.


So, what do you do ? This problem is related to Component Services, and when you open Component Services MMC, you will most probably  get  Error Code 8004E00F COM + was unable to talk to Microsoft Distributed Transaction Coordinator. So, fix the COM+ services first by using the following KB.
PRB: Cannot Expand "My Computer" in Component Services MMC Snap-In
http://support.microsoft.com/?id=301919

If the above didn't solve it, and you still receive the 'Class not registered' error message, then you need to recreate the IIS packages in COM+, try

a) Delete IIS related package in Component Services MMC
• IIS In-Process Applications
• IIS Out-of-Process Pooled Applications
• IIS Utilities

b) Open command prompt, navigate to %windir%\system32\inetsrv folder, and enter (case sensitive)
c:\winnt\system32\inetsrv\>rundll32 wamreg.dll, CreateIISPackage
then
c:\winnt\system32\inetsrv\>regsvr32 asptxn.dll

c) Enter IISRESET at command prompt to restart IIS services, then re-open Component Services MMC to verfiy the IIS packages are recreated.



Updated: 11th May 2005:
If you got this while trying to fix the component services.
Error Code = 0x80040206
Non expected internal error
Not enable to register COM+ events classes.


Try regsvr32 %windows%/system32/ole32.dll, then retry the kb to fix the component services.


Published Tue, Mar 22 2005 11:43 by bernard
Filed under: ,

Comments

# bernard said on 04 April, 2005 07:11 PM
Fantastic, ran through the above and it worked a treat. Many thanks
# bernard said on 23 April, 2005 06:48 AM
hard to Google my way until here, mas worked like a charm ;) To fix the MSDTC just type in the comand line "msdtc -resetlog", and then do the above.. regards
# bernard said on 09 May, 2005 10:15 AM
Thank You so much! I had tried (over & over) to install IIS from the Add & Remove Windows Components with no luck! So I didn't have to delete anything cause it simply wasn't there! But it's there now! Yippie!
# bernard said on 11 May, 2005 07:26 AM
I just found this from Googel searches and it was exactly what I needed to do.

1. comand line "msdtc -resetlog"
2. rundll32 wamreg.dll, CreateIISPackage
3. rundll32 regsvr32 asptxn.dll
4. IISRESET

I can run ASP finally!

Thanks a lot.
# bernard said on 31 May, 2005 11:39 PM
Hi,
I have tried the above, but when I come to:
regsvr32 asptxn.dll
I got this message: DllRegisterServer in asptxn.dll fail.
Returncode: 0x8004e00f

I have googled for a day now, and read 10 Microsoft KB's... but still cant get the answer.

Help me please,

Sam Boman
Sweden
# bernard said on 01 June, 2005 08:25 AM
Hi Sam,

Have you try http://support.microsoft.com/?id=301919 ? and rundll32 wamreg.dll, CreateIISPackage before you try regsvr32 asptxn.dll ?
# bernard said on 20 June, 2005 12:54 PM
Like Sam, I am having no joy here attempting to apply the fix from the KB and also from this page. Any other thoughts?
# bernard said on 22 June, 2005 01:21 PM
Hi Travis,

What do you have in event log now ?
# bernard said on 09 July, 2005 11:35 PM
Thank you very much for sharing this info. This fixed me right up. (got here through Google).

I had trouble running "regsvr32 asptxn.dll", so I dropped back and first followed the steps in the Knowledge Base link you mentioned:
http://support.microsoft.com/?id=301919

rebooted, re-followed your steps, and it works great! Best Regards.
# bernard said on 10 July, 2005 01:05 AM
You're welcomed, Bill. Glad it fixed your problem.
# bernard said on 02 August, 2005 10:21 AM
Thank you! This article solved a problem that was driving me nuts.

You may find that you don't have to reinstall Component Services to fix the problem where the MMC won't open your computer. This fixed that problem for me:

http://www.jsifaq.com/SUBJ/tip4500/rh4593.htm
# bernard said on 03 August, 2005 06:47 PM
Additional troubleshotting steps for XP - refer
http://www.iis-resources.com/modules/newbb/viewtopic.php?viewmode=flat&topic_id=3838&forum=9
# bernard said on 15 August, 2005 11:36 AM
I can't do the following thind.
c:\winnt\system32\inetsrv\>rundll32 wamreg.dll, CreateIISPackage
# bernard said on 15 August, 2005 05:21 PM
Is your %windir% - c:\winnt\ or c:\windows or ???
Navigate to the path first, then excute the command. if you do, then any error msgs while you excute the command?
# bernard said on 23 August, 2005 04:44 PM
c:\winnt\
# bernard said on 23 August, 2005 04:55 PM
What's the error msgs when you run the command? Can you find the rundll32 file ?
# bernard said on 10 September, 2005 01:23 AM
I have the same 'Class not registered' problem, but when I run c:\winnt\system32\inetsrv\>regsvr32 asptxn.dll I get this error:
"DllRegisterServer in asptxn.dll failed
Return code was: 0x800800005"

I realized that in the event viewer(Application) I have this error:

Source: MSDTC
Event ID: 4437
Description:
The account that the MS DTC service is running under is invalid. This can happen if the service account information has been changed using the Services snap-in in Microsoft Management Console (MMC). MS DTC service will continue to start. Please make sure that the MS DTC service account information is updated using the Component Services Explorer.

and also

Source: COM+
Event ID: 4863
Description:
TransactionManager->GetWhereabouts failed. If Distributed Transaction Coordinator is configured to use remote host to coordinate transactions, it is likely that remote host cannot be contacted. You can configure MSDTC to use local coordinator by clicking MSDTC toolbar button in Component Services MMC snap-in. Since further execution is impossible at this time, server process has been terminated.
Server Application ID: {02D4B3F1-FD88-11D1-960D-00805FC79235}
Server Application Instance ID:
{5A2E8651-3C35-4B7D-8AE2-4864339345F7}
Server Application Name: System Application
Error Code = 0x8004d01b : The Transaction Manager is not available.
COM+ Services Internals Information:
File: d:\qxp_slp\com\com1x\src\comsvcs\txprop\dtcinfo.cpp, Line: 164
Comsvcs.dll file version: ENU 2001.12.4414.258 shp


Any ideas??
# bernard said on 10 September, 2005 12:27 PM
First is to fix the MSDTC, then com+, then IIS. So, try
How to reinstall Microsoft Distributed Transaction Coordinator on a computer that is running Windows XP
http://support.microsoft.com/?id=891801
# bernard said on 14 October, 2005 01:28 PM
I followed your steps 100% and ASP pages are now functional on my windows xp prof sp2 dev box.

one note - I stepped along up to this instruction:

a) Delete IIS related package in Component Services MMC...

but there were no component services entries to be found for iis. after thinking about it a bit, i skipped the step assuming a mistake like skipping any step could realistically mean reinstalling the o.s. i mean hey - anything could happen as a result of skipping a step with something that goes slightly over your head. but i did, and continued on picking up with this step:

b) Open command prompt, navigate to %windir%\system32...

I had no other problems. opened ie, went to http://localhost/index.htm to verify that a know loading page would come up, which it did, then jumped to http://localhost/default.asp and bam - hello world.

many thanks
# bernard said on 28 October, 2005 04:53 PM
I ahve a 2k box that I configured for WSUS, didn't test IIS before installation but the WSUSAdmin page created the above error. This fix worked first time, thanks!
# Tim said on 10 February, 2006 04:43 PM
man I have been screwing with this for 1 1/2 years. (it wasn't vital that I run an ASP app on my box but convenient) Finally I don't have to log on somewhere else to debug one of our legacy apps! Weeeeee!
# Suryanto said on 07 April, 2006 10:01 PM
The main problem was MSDTC was not running when we install IIS. During IIS installation it will try to create IIS Package and it failed. If you fix MSDTC problem before installing IIS, IIS installation will sucessfully create the COM+ package, and everything will be fine without manually created IIS pacakge.
# wouter ramon said on 04 May, 2006 09:30 AM
For me, problems disappeared after reading/applying all this comments. I recapitulate for the ones who want to see everything in 1 comment:

A) APPLY http://support.microsoft.com/?id=301919

1. Open registry editor, locate HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\COM3, and then delete this key.
2. From the Start menu, point to Settings, click Control Panel, and then click Add/Remove Programs.
3. Click Add/Remove Windows Components.
4. Proceed through the wizard, and accept all of the defaults.
5. Restart the computer.

B) Start the service Distributed Transaction coordinator

C) Apply the fixes of this webpage

CD %windows%\system32\inetsrv
msdtc -resetlog
rundll32 wamreg.dll, CreateIISPackage
regsvr32 asptxn.dll
IISRESET

Good luck!
# Tomek said on 10 May, 2006 04:16 AM
If you still experience this problem (like I did) you may try to restart and/or unistnall/intall Distributed Transaction Coordinator.
The commands to install/unistall dtc are:
msdtc.exe -install
msdtc.exe -uninstall

You may also check http://support.microsoft.com/?id=891801

Actually I don't know what I did to fix the problem but now I am able to see asp pages and COM+ Applications in Component Services.

HTH
# Chris said on 11 May, 2006 03:14 PM
Thank you, you're a star.
# xinrong said on 14 May, 2006 05:32 PM
thank you so much!

at first i can't do step b.
than i found additional instructions from
http://www.brooksyounce.com/XpAspFix.htm

and i typed
"msdtc -install",
before step B

and then everything works fine!

# john said on 17 May, 2006 02:41 PM
your answer did it A+
# Jan said on 11 June, 2006 09:11 PM
I am having problems when I run the following steps too:

msdtc -resetlog
rundll32 wamreg.dll, CreateIISPackage
regsvr32 asptxn.dll

The error that I faced is warmreg.dll module cannot be found.

May I know if there is anything that has gone wrong?

TIA!
# qbernard said on 11 June, 2006 09:28 PM
Are typing the command at this path ?
%windir%\system32\inetsrv
# Adrian said on 13 June, 2006 04:50 PM
This problem drove me crazy for about 5 hours. I had problems with everything, strarting from the "class not registered", then going through the "regsvr32 asptxn.dll" thing.

Thanks a lot for sharing.

Best regards from Argentina!
# absco said on 15 June, 2006 11:32 AM
Genius!! Thanks
# Andrew said on 15 June, 2006 06:16 PM
I was also getting this error:

Event Type: Warning
Event Source: W3SVC
Event Category: None
Event ID: 36
Description:
The server failed to load application '/LM/W3SVC/1/ROOT. The error was 'Class not registered'.

Using the information in one of the earlier posts by Bernard fixed everything for me (pasted in below). Without step 1, the rest of the steps would not succeed.

Although there is a typo in step 3. It should be just:

3. regsvr32 asptxn.dll

># re: The famous 'Class not registered'
>I just found this from Googel searches and it >was exactly what I needed to do.
>
>1. comand line "msdtc -resetlog"
>2. rundll32 wamreg.dll, CreateIISPackage
>3. rundll32 regsvr32 asptxn.dll
>4. IISRESET
>
>I can run ASP finally!
>
>Thanks a lot.
>Wednesday, May 11, 2005 7:26 AM by bernard
# Rob said on 16 June, 2006 11:19 AM
Fantastic fix to a really irritating (and time consuming) problem!

Thanks
# Channa said on 19 June, 2006 08:18 PM
Just follow these steps

Check in the windows services if Dstributed Transaction Cordinator is insatllled and in "Started" state if not run
1. comand line msdtc -install

Then

2. rundll32 wamreg.dll, CreateIISPackage
3. rundll32 regsvr32 asptxn.dll
4. IISRESET


It should start working
# Saddam said on 05 July, 2006 02:36 AM
I have DLLRegisterServer 0x80040154
error while
rundll32 regsvr32 asptxn.dll
What should I do?
# qbernard said on 06 July, 2006 10:47 PM
Saddam, have you try the first two commands?
1. comand line "msdtc -resetlog"
2. rundll32 wamreg.dll, CreateIISPackage

and during 'regsvr32 asptxn.dll' do you see any addtional event log error?
# Manoj said on 15 July, 2006 01:27 PM
I had faced all the problems listed in this thread.

I finally got it working. Thanks Bernard.
I had to do what you said above:

"First fix the MSDTC, then com+, then IIS."

When I first started with my ASP pages not working, I started searching for help on IIS, and trying to fix that.  Re-installed many times.  No luck.  
More searches lead me to Com+ issues under Component Services. I Couldn't open any folder under My Computer in Component Services.

Then I found this thread, and got stuck at
>rundll32 regsvr32 asptxn.dll
like many people here. I too got that DLLRegisterServer error

But after re-installing MSDTC, everything worked.

So like Bernad, I suggest:
A) APPLY http://support.microsoft.com/?id=301919

B) You may also check http://support.microsoft.com/?id=891801

C)
CD %windows%\system32\inetsrv
msdtc -resetlog
rundll32 wamreg.dll, CreateIISPackage
regsvr32 asptxn.dll
IISRESET

Good Luck
# Ravi said on 23 July, 2006 01:38 PM
Hi,
I am having "class not registered" issue after trying all the steps mentioned above. I will explain my situation in detail below:
1. I installed IIS 5.1 and the front page extensions.
2. I installed VS.NET 2003 and tried to open a  new project. I got the error "can not open the application because no web server was detected at http://localhost/webapplication1"
3. I tried to perform the steps mentioned in your blog exactly as mentioned in the following order.

3.1) I was able to acess the My computer in Component Services MMC Snap-In. Hence i did NOT perform the step to fix the COM+ services first by using the microsoft kb http://support.microsoft.com/?id=301919

3.2)  I directly went to "Delete IIS related package in Component Services MMC" step. Strangely, i found that there was only
IIS Utilities listed in the MMC under MyComputer-->COM+ applications.
I went ahead and deleted each invidual components inside the IIS utilities package i had. I was not able to able to figure out how to delete the IISUtilities directory itself; which wasw empty at this point as i had deleted all of its contents.

3.3)Then i followed the steps b and c as mentioned.
c:\winnt\system32\inetsrv\>rundll32 wamreg.dll, CreateIISPackage -- This step completed sucessfully without any error

c:\winnt\system32\inetsrv\>regsvr32 asptxn.dll - This step completed sucessfully without any error and also recived windows dialog box indicating sucess.

Enter IISRESET at command prompt -- This is where i get the error message again "class not registered".

Please help me ..i had been trying to solve this problem from a long time..Thanks

# qbernard said on 23 July, 2006 11:16 PM
Ravi,

First, do you have any other event log ? like MSDTC? if your com+ catalog is fine, then you can skip it. but i would still prefer you follow the steps, especially on the add/remove program wizard, just click 'next' all the way, it will clean up com+ catalog... the reapply all other steps.
# Ravi said on 24 July, 2006 11:53 AM
Hi Bernard,
Thank you very much for the help. Actually the issue was resolved using a different approach. Seems like McAfee was the main culprit. I will explain the problem in detail so that someone else will not waste time like i did:
1. I installed IIS when McAfee was turned ON.
2. I encountered the class not registered error.
3. I uninstalled/turned OFF my McAfee security center.
4. I uninstalled my IIS using the windows components add/remove option in control panel.
5. I installed IIS again and Voila! everything is perfect. I did not have to go through any of these steps listed above.

Please note that i tried installing IIS several times after i encountered error. But the most important thing i realised is that "IIS did not install itself properly with McAfee turned ON. So everytime i tried to reinstall windows perhaps realised that IIS was already installed and did nothing."
ONLY AFTER I TURNED OFF McAFEE, UNINSTALLED IIS AND THEN REINSTALLED IIS, It was sucessful!
# qbernard said on 24 July, 2006 08:02 PM
Cool. This is the first time I see McAfee name with this error msgs. I know McAfee does break or prevent IIS to function probably. but causing this error? mm... what McAfee product did you install?
# David Laub said on 27 July, 2006 04:02 PM
I just purchased an HP Pavillion dv8000 laptop & ran into this exact problem - AFTER I installed Visual Studio 2005 Express products.  I'll never know if Component Services was screwed up fresh from the factory or occured after downloading the Microsoft software.
# yilaylay said on 29 July, 2006 11:53 AM
Yeah,it works.
It spent me one week to solve the problem.
If I didn't happen to see your post , my
nightmare would reside always. Thank you!!!!
# bswain said on 13 August, 2006 06:18 PM
My HP Pavilion dv8000 also has this problem.  I reset it to factory defaults with their recovery tool, tested Com+ and it failed.  This means that  COM+ was broken as it came from the factory.

HP support didn't help and stopped receiving my requests for help.

Anyone else having problems with their Pavilion dv8000?  Maybe there's a problem with this computer?
# qbernard said on 16 August, 2006 12:55 AM
Wow! HP stop helping you? Mmm... anyway have you try to fix the com+ error base on the suggestion? what do you got in event log ?
# frankienapoli said on 03 September, 2006 08:27 PM
Yep, same problem with an hpdz8000. What a pain. I purposely got XP Pro for ASP.NET development. My desktop with Media Edition works fine.
# frankienapoli said on 06 September, 2006 06:35 PM
Sorry for the confusing previous post. I have an HP Pavillion dv8000z, the AMD model. I popped for XP Pro to do contract work at a variety of places and wanted the connectivity features. I have Media Edition on a desktop at home. Both OS's can run IIS. The dv8000z has the exact problem. Don't know if it's XP Pro, the box, or what. I haven't tried to fix with this method yet but will when I can risk the machine blowing up. Thanks all. Frank
# qbernard said on 06 September, 2006 09:45 PM

I don't know what is loaded with dv8000z. is it XP Pro, are you having the 'class not registered' error msgs or ?  have you install IIS ?

# Mike K said on 08 September, 2006 07:33 AM
Thansk for the great tip. I ran the cited KB and dll commands in the top post and it FINALLY works after 2 days of searching for the answer.
# Ray said on 12 September, 2006 04:04 PM
My problem is that my ASP pages just will not execute on XP Pro...no error messages or anything, they just freeze up and do nothing. It's the most frustrating thing I have ever encountered!!! I disabled McAfee, uninstalled and reinstalled, ran all the tips above (no errors), set security permissions, did the works. Pure HTML works fine, but when I load an ASP page the browser loads forever...a permanent FREEZE with no error messages. Is there somebody who can shed some light on this behaviour? Please... Ray
# Ray said on 13 September, 2006 06:19 AM
I had a slightly different problem. My ASP just would not execute...no error messages to lead me on, the page just loaded forever. I tried all the fixes noted above, but it still did not work. I even reinstalled with McAfee disabled and did all the fixes again. By chance I picked up a tip through another forum that my GLOBAL.ASA file could be the problem, so I renamed it and WHAM, the ASP ran like a dream! However, that was not the end of my misery because no database access was possible without GLOBAL.ASA, so I continued my research and discovered that the Function FrontPage_FileExists(fspath) was the guilty party. I modified it as follows: Function FrontPage_FileExists(fspath) On Error Resume Next FrontPage_FileExists = False set fs = CreateObject("Scripting.FileSystemObject") 'begin of replacement part if (fs.FileExists(fspath)) then FrontPage_FileExists = True end if 'end of replacement part 'begin of deleted part ' Err.Clear ' set istream = fs.OpenTextFile(fspath) ' if Err.Number = 0 then ' FrontPage_FileExists = True ' istream.Close ' end if ' set istream = Nothing 'end of deleted part set fs = Nothing End Function Again, that was not the complete solution as I got an ODBC error as follows: Microsoft OLE DB Provider for ODBC Drivers error '80004005' [Microsoft][ODBC Driver Manager]Data source name not found and no default driver specified. The solution to that is too long to describe here, but you can find it at: http://support.microsoft.com/kb/306345/EN-US/ After doing what they told me I restarted the IIS using IISRESET and I was SOLVED!! I hope this helps somebody as it is invaluable information that can take days to find...
# qbernard said on 15 September, 2006 01:12 AM

Thanks Ray for sharing your solution.

# Frank M. Allen (aka frankienapoli) said on 17 September, 2006 12:34 PM
Success!!! Here is what I found on my HP dv8000z. It looks like the MSDTC service was never installed. All I did was: uninstall IIS. run msdtc.exe -install run msdtc.exe -resetlog start msdtc service install iis run aspnet_regiis -i In IE I type /localhost and get the welcome page. I start VS, create a C# Web App that defaults to /localhost/WebApplication1 and I go back to IE /localhost/WebApplication1/WebForm1.aspx and it works. Thanks all for all the info. Because this is showing up on the HP boxes, I suspect they just neglected to install MSDTC service when they set the boxes up. Anyway, I hope that helps someone else. I was anticipating a long afternoon but didn't have to edit the registry at all and it took about 15 mins. Good luck all. Frank
# qbernard said on 17 September, 2006 08:33 PM

Yeah, glad you fixed it.

# Mark said on 18 October, 2006 10:40 AM
I was getting all of the above. However my event log also showed that MSDTC was not starting up. My fix script was as follows: :: repair MSDTC cd c:\windows\system32\ msdtc -uninstall msdtc -install msdtc -resetlog :: repair IIS Package cd c:\windows\system32\inetsrv rundll32 wamreg.dll, CreateIISPackage regsvr32 asptxn.dll IISRESET Ran in under a minute and worked like a charm. This was my first time using ASP on this XPSP2 box, so it may never have been working. The MSDTC errors go way back in my log. I cannot provide any insight as to the all important when did it started. Root cause(s) remain unknown...
# qbernard said on 18 October, 2006 07:46 PM

So you got the same error again?

# Steve said on 20 October, 2006 07:21 PM
I thought I should add to Ravi's problem with McAfee Virus scan.. This problems also occurs when Norton AntiVirus Auto Protect is enabled. So, when installing IIS remember to switch your virus scanner OFF!
# Chris said on 23 October, 2006 09:11 PM
Awesome! I don't normally leave comments, but this just saved me too much time not to voice my appreciation. Well Done.
# www.consultmelive.com » To fix http 500 error on HP Pavillion 5000 after Dot Net and IIS Install. said on 10 January, 2007 05:05 PM

PingBack from http://consultmelive.com/2007/01/10/to-fix-http-500-error-on-hp-pavillion-5000-after-dot-net-and-iis-install/

# error code 8004e00f said on 08 April, 2008 07:23 PM

Pingback from  error code 8004e00f

# class not registered said on 10 May, 2008 02:17 PM

Pingback from  class not registered

# IIS - Internal Server Error, Class not registered « Caveman’s Blog said on 23 June, 2008 03:58 PM

Pingback from  IIS - Internal Server Error, Class not registered « Caveman’s Blog

# IIS - Internal Server Error, Class not registered « Caveman’s Blog said on 23 June, 2008 03:58 PM

Pingback from  IIS - Internal Server Error, Class not registered « Caveman’s Blog

# IIS - Internal Server Error, Class not registered « Caveman’s Blog said on 23 June, 2008 03:59 PM

Pingback from  IIS - Internal Server Error, Class not registered « Caveman’s Blog

# IIS - Internal Server Error, Class not registered « Caveman’s Blog said on 23 June, 2008 03:59 PM

Pingback from  IIS - Internal Server Error, Class not registered « Caveman’s Blog

# IIS - Internal Server Error, Class not registered « Caveman’s Blog said on 23 June, 2008 04:15 PM

Pingback from  IIS - Internal Server Error, Class not registered « Caveman’s Blog

# IIS - Internal Server Error, Class not registered « Caveman’s Blog said on 23 June, 2008 04:15 PM

Pingback from  IIS - Internal Server Error, Class not registered « Caveman’s Blog

News

Search

Go

This Blog

Tags

Archives

IIS Sites

MVPs - MVPs

IIS Related

Syndication