7

I published my Web Api (framework 4.5) in this path:

C:\inetpub\wwwroot\MyWebAPI

In my IIS, I converted this folder to an app

When i try to access this URL http://localhost/MyWebAPI/api/client/1 the message appears:

Service Unavailable
HTTP Error 503. The service is unavailable.

Why is this?

Update

My App Pool is set to be "STOP". When I turn it on, it goes back to "STOP"

KyleMit
  • 30,350
  • 66
  • 462
  • 664
Liev04
  • 401
  • 1
  • 5
  • 13

4 Answers4

9

I found the solution

  • Click on Application Pools under the tree with your machine name,
  • on the right side, click click on Advanced Settings,
  • in Process Model change the "Load User Profile" to false
  • Start your application and restart your IIS

The error will surely change, in my case the error changed to this one

"Config Error: This configuration section cannot be used at this path. This happens when the section is locked at a parent level. Locking is either by default (overrideModeDefault="Deny"), or set explicitly by a location tag with overrideMode="Deny" or the legacy allowOverride="false"."

I have found the solution for this other problem here Config Error: This configuration section cannot be used at this path

Liev04
  • 401
  • 1
  • 5
  • 13
1

This is a fairly old thread, but I stumbled across it with the same issue. For me, the resolution was to reset the App Pool user. I was starting the site, but the app pool would just stop. No logs, nothing. I recently had to change my windows password and the app pool user (me) was using the old password :-)

(note my website continued to work for a few days with the old password until I did an iisreset which is when the problem started)

stuartw87
  • 119
  • 2
  • 9
0

Run the following commands in PowerShell in administrator mode.

  1. Stop-Service -Force WAS
  2. Remove-Item -Recurse -Force C:\inetpub\temp\appPools\*
    • If the above command not working, delete files manually.
  3. Start-Service W3SVC
Michael
  • 8,362
  • 6
  • 61
  • 88
Gehan Fernando
  • 1,221
  • 13
  • 24
0

You might stop App pool, start it and error will be gone.

Sheriff
  • 738
  • 10
  • 20