IIS Express crashes when starting a site from visual studio

65,103

Solution 1

In your project folder find the hidden .vs folder and delete it. This solved the problem for me.

Solution 2

On my code this error was caused by an infinite loop, try to check if you have a loop like that in the following example:

public int InfinitiveLoop(long param)
{
    return InfinitiveLoop(param);
}

Solution 3

Considering faulting module is not on IISExpress's dll files, this might be caused by either your web project or an unknown VS issue.

One thing we can try is to start the problematic web site without using VS. You can execute IISExpress.exe with /siteid option. You can find the site id from applicationhost.config which is placed on the config of IISExpress directory.

For example, if the site id is 2, you can run this command:

"\Program Files\IIS Express\iisexpress.exe" /siteid:2

If the web site still does not work, showing the Access Violation issue which you ran into when you launched the website via Visaul Studio, maybe you will need to narrow down the issue why that happens.

If the web site runs okay if you don't use Visual Studio, it might be caused by some Visual Studio issue. In that case, considering you used RC build of Visual Studio, you will need to upgrade VS 2015 first and check if the issue is still reproducible.

Solution 4

On top of all answers here, I believe this answer can be helpful to figure it out why this issue occurred: System.StackOverflowException. I started my application without debugging and the two errors were IIS crashed and vstest.executionengine.x86.exe has stopped working (when trying to run the unit tests). Unfortunatelly, in the window event viewer I wasn't able to see the actual error. I saw it just when I started my application with debugger. So, if you have one of these errors, before doing some other investigations, please check your code. Because I was dumb, it took me 1 hour of my work time :(

Solution 5

Try deleting .vs folder from your project folder. Found the solution here

Share:
65,103
Joshua Barron
Author by

Joshua Barron

Updated on January 08, 2022

Comments

  • Joshua Barron
    Joshua Barron over 2 years

    I started encountering this problem after installing the Visual Studio 2015 RC; I am no longer able to debug web projects from Visual Studio 2013.

    My projects build fine and VS launches a browser - I can see in my output that iisexpress.exe loads all the relevant DLLs for the project, but then right when I would expect to see my website, iisexpress.exe stops running and Visual Studio stops debugging. All the output Window tells me is this:

    The program '[3724] iisexpress.exe: Program Trace' has exited with code 0 (0x0).
    The program '[3724] iisexpress.exe' has exited with code -532462766 (0xe0434352).
    

    Looking in the event viewer I see the following crash info for iisexpress.exe:

    Faulting application name: iisexpress.exe, version: 8.0.8418.0, time stamp: 0x4fbaa9e8
    Faulting module name: KERNELBASE.dll, version: 6.1.7601.23040, time stamp: 0x553e86a2
    Exception code: 0xe0434352
    Fault offset: 0x0000c44d
    Faulting process id: 0x1b40
    Faulting application start time: 0x01d094d5c74c69d5
    Faulting application path: C:\Program Files (x86)\IIS Express\iisexpress.exe
    Faulting module path: C:\Windows\syswow64\KERNELBASE.dll
    

    I've tried reinstalling IIS, deleting my local IISExpress folder, and still no luck. Anybody have an idea how I can get IIS running again?

  • Russell Jonakin
    Russell Jonakin about 7 years
    I am helping tutor some students and I am reviewing their code that they send to me. I had the problem described by the OP for many of the projects sent to me when I try to open in visual studio. After trying a few different suggested solutions that did not work, your solution WORKS EVERY TIME this problem occurs and it is a very simple solution. +1
  • kernowcode
    kernowcode about 7 years
    Sometimes you just need a solution to continue to be productive.
  • Dinesh Kumar P
    Dinesh Kumar P almost 7 years
    Worked for me too. But if we know the reason / issue details it will be more helpful for all.
  • Agnes Simpson
    Agnes Simpson about 6 years
    PS:- May be because this folder contains machine specific info. And if you are using subversion software then chances are this folder is commit by some person and when you update your project this other guys .vs will mess with yours. If this is the case then unversion this folder so as to avoid this error in future.
  • Gabriel Marius Popescu
    Gabriel Marius Popescu over 5 years
    I thought I had this problem fixed by using sony vizio suggestion, but actually my problem was somewhere else.
  • Jitendra Tiwari
    Jitendra Tiwari over 5 years
    awesome :) you save my time.
  • Kundan
    Kundan over 4 years
    In my case the API call to TFS was failing due to incorrect parameter sequence, passing correct parameters worked for me.
  • Thulasiram
    Thulasiram about 4 years
    Working Fine. Thanks :)
  • TwitchBronBron
    TwitchBronBron almost 3 years
    Yes, this was my problem as well! It's interesting that Visual Studio wouldn't show the exception inline before crashing.