Error 503 Service Unavailable when using localhostRSS

10 replies

Last post Dec 10, 2012 07:09 AM by yardpenalty

  • Error 503 Service Unavailable when using localhost

    Mar 22, 2011 07:09 PM|David Beechcroft|LINK

    I am having problems loading web pages using localhost using Windows 7 and IIS7.5. It was all working fine until I installed some Microsoft updates including Windows 7 Service pack 1 when I started getting error 503 Service Unavailable.I posted a message on the Microsoft forum related to Windows updates, but all the suggestions for resolving or identifying the problem were unsuccessful.
    After uninstalling Windows7 SP1, turning off IIS Manager in 'Programs and Features' in the control panel,then turning on IIS with the default configuration, Localhost appeared to be working correctly, and continued to work correctly after reinstalling Windows 7 SP1. I then reconfigured IIS to run PHP scripts following the instructions on http://technet.microsoft.com/en-us/library/dd239230(WS.10).aspx?ppud=4
    but the error 503 returned.
    I have uninstalled PHP, turned off IIS, re-installed PHP and reconfigured IIS and still get the same error message.
    If I look in the 'Windows Logs/System section of 'Event Viewer' (in Control Panel/Administrative Tools'), I find 5 warnings and 1 error message all within a space of 2 seconds at the time I attempted to load the web page.
    The warnings ar all the same, and are
    Source: WAS
    Event ID: 5022
    level: Warning
    Description:
    The Windows Process Activation Service failed to create a worker process for the application pool 'DefaultAppPool'. The data field contains the error number.
    Data: 8007012B
    The error message is
    Source: WAS
    Event: 5002
    Description
    Application pool 'DefaultAppPool' is being automatically disabled due to a series of failures in the process(es) serving that application pool.
    There is a 'Help' hyperlink at the bottom of the Warnings which takes me to a web page where I can download a utility named 'Err'
    Running this utility and passing it the data in the warning gives the following additional information.

    D:\Err>err 8007012b
    # as an HRESULT: Severity: FAILURE (1), Facility: 0x7, Code 0x12b
    # for hex 0x12b / decimal 299 :
      MCIERR_NEW_REQUIRES_ALIAS                                     mmsystem.h
      SQL_299_severity_16                                           sql_err
    # The DATEADD function was called with bad type %ls.
      ERROR_PARTIAL_COPY                                            winerror.h
    # Only part of a ReadProcessMemory or WriteProcessMemory
    # request was completed.
    # 3 matches found for "8007012b"

    At the same time as this error and warnings are generated, 2 new folder chains are created in the c:\Users folder and are
    TEMP.IIS APPPOOL.006\AppData\Local\Microsoft\VisualStudio\
    TEMP.IIS APPPOOL.007\AppData\Local\Microsoft\VisualStudio\
    There are no other files or folders in any of these sub-folders.

    If I go to IIS Manager after the error has occured and from the server node select Worker Processes, no processes are listed.
    The PHP script I am attempting to load just consists of
    <?php
    phpinfo();
    ?>
    I am at a loss to know where to go from here.

  • Re: Error 503 Service Unavailable when using localhost

    Mar 22, 2011 11:49 PM|HCamper|LINK

    Hello,

    I have several suggestions for the listed problems:

    The first is please use the guides that are are in located at IIS Net Learning Section of this Forum.

    The guides at IIS Net are being updated more often that those in the MSDN library.

    I hope this helps,

    Martin

     

      

    Windows and Linux work Together IT-Pros
    Community Member Award 2011
  • Re: Error 503 Service Unavailable when using localhost

    Mar 31, 2011 06:38 AM|David Beechcroft|LINK

     Thank you for your suggestions.
    I have checked the permissions for IUSR, IISUSERS, and in inetpub and all its subfolders it has read, list and execute permissions.
    I have also checked the IIS Server, AppPool and Windows\temp folders which all have full permissions.
    I have been making my way through the troubleshooting section, and as the DefaultAppPool is being stopped before it can do anything due to the Rapid Failure Protection (the worker process fails five times which stops the DefaultAppPool) I am working my way through Mike Volodarsky's blog: "Troubleshooting IIS7 503 'Service Unavailable' errors with Startup debugging." at

    http://mvolo.com/blogs/serverside/archive/2007/05/19/Troubleshooting-IIS7-503-_2200_Service-unavailable_2200_-errors-with-startup-debugging.aspx.
    As instructed I downloaded and installed the latest debugging tools from http://msdn.microsoft.com/en-us/windows/hardware/gg463009.aspx
    As the error is occurring on every attempt to access http:\\localhost\test\test.php I could not debug the process by supplying the PID (step 3) as the process had already stopped.
    I therefore went on to step 4 to set up startup debugging.
    I modified the registry as instructed, but as the debugging tools had been installed in a different directory to the one specified, ntsd.exe was in c:\Program Files\Debugging Tools for Windows (x86)\  my REG command looke like this:

    REG ADD "HKLM\Software\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\w3wp.exe" /v Debugger /d "c:\Program Files\Debugging Tools for Windows (x86)\ntsd.exe -server npipe:pipe=w3wp -g" /t REG_SZ /f

    Checking the registry confirmed that ...\Image file Execution Options\w3wp.exe included Debugger REG_SZ c:\Program Files\Debugging Tools for Windows (x86)\ntsd.exe -server npipe:pipe=w3wp -g

    I then re-started the DefaultAppPool and attempted to load http:\\localhost\test\test.php to trigger the error (step 5)

    From an elevated Command prompt I changed directory to c:\Program Files\Debugging Tools for Windows (x86)> then executed
    windbg -remote npipe:server=localhost,pipe=w3wp

    The debugger started. Hower It displayed the error message "The debugger could not contact the remote server given in npipe:server=localhost,pipe=w3wp" and went no further - no stack dump, just a blank debugger window!

    I have double checked the registry entry, file locations and command line (including spelling, punctuation and capitalization) and all check out ok.
    I tried running Windbg with no parameters then from the file menu 'connect to remote session' then entering npipe:pipe=w3wp into the Connection String. This resulted in exactly the same error as before!

    Am I missing something? What am I doing wrong?

    I am running IIS7 on Windows 7 Ultimate and Internet explorer 9

  • Re: Error 503 Service Unavailable when using localhost

    Mar 31, 2011 09:36 AM|HCamper|LINK

    Hello,

    Ok, Then your dealing with three different tasks & issues.  

    To work  with using IE9 turn off friendly error messages change the Intranet net security settings to allow code and scripts to run. 

     You should be able to now test the php using the <?php phpinfo(); ?> in test.php in the root directory at C:\InetPUB\wwwroot\test.php.        

    Your best guide for configuration & set-up for FastCGI and IIS Server settings is in the IIS Net Learning library.

    I hope I have not missed something.

    I hope this helps,

    Martin

     

    Windows and Linux work Together IT-Pros
    Community Member Award 2011
  • Rovastar Rovastar

    5482 Posts

    MVP

    Moderator

    Re: Error 503 Service Unavailable when using localhost

    Mar 31, 2011 11:27 AM|Rovastar|LINK

     Although a lot of information here also the http.sys error logs might help. 503 errors are produced by the http.sys not IIS so look in there it might shed some more light.

     

    Troubleshoot IIS in style
    https://www.leansentry.com/
  • Re: Error 503 Service Unavailable when using localhost

    May 13, 2011 02:38 AM|lpfcbrain|LINK

    Hi David

    Did you find a solution to your problem?

    /Lotte

  • Re: Error 503 Service Unavailable when using localhost

    Jul 01, 2011 10:46 AM|McG_Highlander|LINK

    Hi,

    I had this issue before. 

    In the Event Viewer, check to see if there is a permissions issue with these "TEMP.IIS APPPOOL.xxx" folders.

    The issue is with the additional users being created in the C:\Users folder.

    I resolved by:

    Opening IIS and Application Pools ensure "DefaultAppPool", and any other Application Pools your websites use. Click advanced settings for each of these. Ensure the "Load User Profile" is set to 'False'

    Also ensure that the "Set Application Pool Defaults" has the Load User Profile set to False.

  • Re: Error 503 Service Unavailable when using localhost

    Jul 04, 2011 06:43 AM|jarrods7v7n|LINK

    Ahhh Thank you so much, this worked for me!!! Thanks McG_Highlander.

  • Re: Error 503 Service Unavailable when using localhost

    Nov 17, 2011 04:51 PM|lloydmalvern|LINK

    Getting similar error; used err.exe. See output below. 

    Turning off load profile has allowed me to open up the website on localhost! WooHoo.  Thanks, McG_Highlander, for this. Spent most of the day tracking this down.

    err 8007012b
    # as an HRESULT: Severity: FAILURE (1), Facility: 0x7, Code 0x12b
    # for hex 0x12b / decimal 299 :
      MCIERR_NEW_REQUIRES_ALIAS                                     mmsystem.h
      SQL_299_severity_16                                           sql_err
    # The DATEADD function was called with bad type %ls.
      ERROR_PARTIAL_COPY                                            winerror.h
    # Only part of a ReadProcessMemory or WriteProcessMemory
    # request was completed.
    # 3 matches found for "8007012b"

  • Re: Error 503 Service Unavailable when using localhost

    Sep 03, 2012 02:09 PM|DerikJ|LINK

    McG_Highlander

    Click advanced settings for each of these. Ensure the "Load User Profile" is set to 'False'

    Also ensure that the "Set Application Pool Defaults" has the Load User Profile set to False.

    This worked for me too, great post! Thanks for sharing the information! I wish I could mark this as the answer so other would find it more easily, but I couldn't find that option.

    answer

  • Re: Error 503 Service Unavailable when using localhost

    Dec 10, 2012 07:09 AM|yardpenalty|LINK

    David -

    I am having the same exact problem. I downloaded some update and now my machine(WIndows 7 x86) keeps 503ing because every app pool shutdown no matter what suggestion I use. I have tried everything under the sun to solve his issue. I even did a system restore and it still doesn't work. I re-installed .NET 4.5 and it worked for a session and then the same problem persisted. What a turn to Microsoft products. I have been studying asp.net for the last three years and have enjoyed it, but have been doing a bunch of Linux based web development and while .NET pays more I am starting to go the other route. At least for my web site needs. It is a shame that something as bi as IIS has problems like this.