Server application unavailable: installing IIS on .NET 2.0

I feel so dirty, but for a project I’m working on at the moment I have to use ASP.NET instead of PHP; “why?” is a question for another day. Anyway, I’ve installed IIS before so that wasn’t a big problem… or so I thought.

I already had the .NET 2.0 framework on my XP machine so went straight to installing IIS (5.1 comes with XP Pro). It installed easily enough and my hello world html file was served without any major problems (actually that’s not true, before I copied my own files across I tried to check the IIS default pages served ok only to discover, through more googling, that if I used IE instead of Firefox that annoying box asking me for a password would go away).

Now my ASP.NET issue. I got a Server application unavailable error message in big red letters when I tried to run any .aspx (ASP.NET) scripts and couldn’ t figure ou

t for the life of me why. The Event Viewer, where IIS errors are logged, gave little more by way of help: Failed to initialize the AppDomain:/LM/W3SVC/1/ROOT

Err… What?! I worked out that it wasn’t affecting html pages, just ASP ones – and only .aspx ones at that, suggesting it was .NET-related.

As it turns out the problem was that I had installed .NET before IIS. It’s easy enough to fix, but it took 20 solid minutes of googling to find the solution in a Microsoft community newsgroup (and then realise that I’d have found it already if I’d just read to the bottom of a 4 year old forum post I’d already found).

Anyway, what you need to do if you’re getting this “Server application unavailable” message is navigate to your .NET directory (something like C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727) in a command prompt and run the command aspnet_regiis.exe -i which will register ASP.NET with IIS. If that still doesn’t work, there’s always PHP.net 😉

Author: nerd.

An experienced IT professional, I used to run a number of small websites and spend a lot of time tinkering with my sites or my PC - back when I had free time.

49 thoughts on “Server application unavailable: installing IIS on .NET 2.0”

  1. OMG, I just spent 3 hours trying useless fix after useless fix trying to solve this problem. I’m putting you in my will. 🙂

  2. Great. I’ve been searching to fix this problem. Working on a job where I have to use ASP instead of PHP. Even amidst the pain, your parting remark about PHP.net brought a smile.

    Thanks.

  3. Very nice – worked a real treat for me!! Like the PHP.net remark too 😀

    “Server application unavailable” fixed by aspnet_regiis.exe -i

  4. I’m working on this very same issue and things seem fine so far but one question….do I navigate and run the command from the most current ASP.NET 2.0.50727 directory or do I run the command under the directory for the ASP.NET version(1.1.4322 ) that the site was using before? I see after I run it under the 2.0 directory it obviously changes the asp.net version used by the site to 2.0…

  5. Jay,

    I’m not an expert on Microsoft’s .NET platform, so please bare that in mind when reading the following.

    The issue I described resolved an issue when you install IIS after the .NET framework. If you already had a site running that would suggest you had IIS first and then installed .NET, in which case the .NET framework should register itself with IIS during installation. Maybe your site needs to be run under .NET 1.1 (in which case you should be able to select the .NET version to use by going to the web site’s properties in IIS manager and looking under the ASP tab).

    HTH.

  6. I line up with the others, thanking you a lot for this tip. I had the exact same problem – and your tip simple did the job.
    I am no .NET nor ASP man at all, so I could have spent days in the cyberjungle searching for knowledge if I hadn’t stumbled over your tip here pretty early – by pure coincidence.
    You made my day – thanks again 🙂

  7. Yeah good one thanks.

    On XP pro. Had everything running fine with asp.net 2.0 (never had v1.0 or 1.1) and after installing some updates the dreaded “server application unavailable” took over. Ponderous.

  8. Transfered site from Server 2003 to XP Pro and over thought the problem. This simple little fix solved my issue. Thanks for publishing!

  9. Sir,
    I have tried it but still i am getting problem.Actually when i am hitting “http://localhost” ,the page is calling oracle http server not microsoft’s.Please help me how can i solve this issue.

  10. I’m so glad!
    I got fixed a problem that took 2 whole work days (8+8=16hours) to solve this problem, until i found this!!
    Thank you very very much!

  11. Dude, you totally saved me. Though, I’d rather use perl with a flaming spear in my chest than deal with this IIS, ASP.NET trash. Makes me wanna try mono. Anyway…thanks again!

  12. Thank you very much ,,,,,,,,,, issue fixed and but we need to enable it on IIS to remove the 404 for not found error after the installation as

    1. Open up the Internet Information Services (IIS) Manager (which you find under Administrative Tools)
    2. Expand your server
    3. Select Web Service Extensions
    4. In the right hand pane, click ASP.NET v2.0.50727 (or a later version number) and then click the Allow button.

    Riyas

  13. Thanks for the post – seems you’re 3rd on Google for “IIS XP asp.net Server Application Unavailable” – saved me a heck of a lot of looking around.

  14. As Matt said, I found your site from Google. I only wish I viewed your site before spending countless hours wasted on trying to figure out what was wrong. Thanks!

  15. Thanks it works.
    a brief manual:
    Register .net framework with iis
    in command prompt
    ———————————-
    C:
    CD\
    CD C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727
    aspnet_regiis.exe -i

  16. Hi

    I have IIS 5.1 and asp.net 1.1,2.0 on my pc (WIN XP). I am able to regiter IIS with asp.nwet 1.1 but while registering IIS with ASP.NET 2.0 1 error is writtein in log file ASPNETSetup_00002.log

    Failure Determining if we are running on a domain controller: IsDomainController failed with HRESULT 80070842: ‘The Server service is not started. ‘

    can you please provide the resolution of thei problem

    Thanks

  17. I needed to also do this for the aspnet v4 directory to get my website to work. We only use the ASP.net V2.0 for our site. the directory for this is \Windows\Microsoft.net\Framework\V4.0.30319

    Thanks for getting me started in the right direction.

Leave a Reply

Your email address will not be published. Required fields are marked *