Debugging Solution

Jan 3, 2011 at 10:41 AM

Hello,

Happy new year to all !!

When I try to debug the solution, I cannot initialize the WebServer, every time I got "file not found", but IIS 7 is correctly installed and running. The DLL "hwebcore.dll" is present into "C:\Windows\System32\inetsrv".

Could you provide some help ?

Thank you

Coordinator
Jan 18, 2011 at 4:11 AM

Hi Jonaze -

There are several scenarios where you might see a file not found.  Can you provide some context on when/where this is occuring? 

To clarify 'cannot initialize the WebServer'.  Do you mean that it gets through dependency resolution without issue and fails on the final call into native code to start the HWC?  If so, here is what comes to mind:

 

Idea 1:   Ensure you have enabled the platforms Hostable Web Core feature.  There is a great response with more detail in another thread in this forum. 

Idea 2:   Ensure you have installed IIS Redirection.   This can be done through the Web Platform Installer or independently.  The Azure platform has the redirect.dll assembly installed in its GAC, and it is the only required feature which is not part of the Azure SDKs or Windows Server platform.  The applicationHost.config file taken from Azure references this assebly and will fail if it cannot be not found.  (We want to mirror the Azure HWC web role configuration as exactly as possible for consitency accross dev and production environments; and implemenations of roles; thus, simply, removing the assembly reference is3n't viable, independant of whether its functinality is in use.) 

Idea 3:  Check the windows event log.  There will be a class of errors under a category of Hostable Web Core.  The most common is Idea 2.

Idea 4:  Ensure that all the right things happen re: the cloud drive.  If its in the dev fabric this includes setting it to be created (if not exist) in the XML definition.  And then migrating your bits to the drive the first time it mounts.  This only has to be done the first time you simulate in the local dev fabric.  There is another post, and information in the guides which better explains and walks through getting this set up.)

Idea 5:  WebServer as configured for hosting does not match the corresponding physical site and application structure.  Things to look for:

  • Umbraco at Root:  the Umbraco website should be installed as the root of its own site, and not as a virtual directory.  The WPI will allow either.  The Umbraco team highly recommends it being the root of an IIS site.
  • Umbraco as Virtual Application:  if you go this route anyway, ensure that you either have a valid web.config in the web site root (Umbraco definition inherits the IIS 7 definition).  The IIS7 definition currently defines the IIS site root as an application root.  If the physical reality is simply an empty folder with Umbraco in a sub-folder, it will throw an error regarding the missing application (file).  Also, if Umbraco itself is configured as the root of a web site, but is actually in a virtual directory, HWC will bail due to the configuraiton definitions which are not allowed anywhere but an application root.  (The error will reference elements being defined which cannot be overridden at the level found).  This can be resolved by ensuring that the Umbraco definitions includes this application requirement.  (Although many applications may defined, and services running, they all share the same application pool.)

Idea 6:  Please post the startup trace log from the last dozen or so events prior to failure.  In particular, the two log entries prior to starting IIS in-proc will dump the entire list of Variables as they have been resovled, and the HWC as it is provisioned and configured prior to our call to instantiate then start.  The usually provides sufficient information to understand what is incorrect.

Let me know.  I have a few more thoughts but don't want to make this appear more daunting it is.

Best Regards,

Ryan