Website deployment failure after today's DM upgrade

SteveGTRSteveGTR Posts: 91
edited November 14, 2013 2:49PM in Deployment Manager
The website no longer deploys after installing today's DM upgrade. Everything goes well and all the files are deployed, but it fails after that. Here's the log information:

2013-11-13 13:07:45 -05:00 INFO Extracting package contents to 'c:\inetpub\wwwroot'
2013-11-13 13:09:02 -05:00 DEBUG Looking for PowerShell scripts named Deploy.ps1
2013-11-13 13:09:02 -05:00 DEBUG No scripts called Deploy.ps1 were found.
2013-11-13 13:09:02 -05:00 INFO Updating IIS website Default Web Site. You can use the RedGateWebSiteName project variable to override an IIS site name. If you don't specify the variable, the package name is used.
2013-11-13 13:09:02 -05:00 ERROR Error while executing job: Retrieving the COM class factory for component with CLSID {2B72133B-3F5B-4602-8952-803546CE3344} failed due to the following error: 800700c1 is not a valid Win32 application. (Exception from HRESULT: 0x800700C1).
System.BadImageFormatException: Retrieving the COM class factory for component with CLSID {2B72133B-3F5B-4602-8952-803546CE3344} failed due to the following error: 800700c1 is not a valid Win32 application. (Exception from HRESULT: 0x800700C1).
at Microsoft.Web.Administration.ConfigurationManager.CreateWritableAdminManager(WebConfigurationMap webConfigMap, String configPathToEdit, Boolean isAdminConfig)
at Microsoft.Web.Administration.ConfigurationManager.CreateConfiguration(WebConfigurationMap configMap, String configPathToEdit, Boolean isAdminConfig)
at Microsoft.Web.Administration.ConfigurationManager.GetConfiguration(String rawConfigurationPath, String cacheKey, Boolean isAdminConfig)
at Microsoft.Web.Administration.ConfigurationManager.GetApplicationHostConfiguration()
at Microsoft.Web.Administration.ServerManager.get_SitesSection()
at Microsoft.Web.Administration.ServerManager.get_Sites()
at RedGate.Deploy.Agent.Deployment.Integration.Iis.IisServerExtensions.GetSite(ServerManager serverManager, String webSiteName)
at RedGate.Deploy.Agent.Deployment.Integration.Iis.WebServerSevenSupport.FindVirtualDirectory(String webSiteName, String virtualDirectoryPath, Action`1 found)
at RedGate.Deploy.Agent.Deployment.Integration.Iis.WebServerSevenSupport.ChangeHomeDirectory(IisSiteInformation siteInfo, String newWebRootPath)
at RedGate.Deploy.Agent.Deployment.Conventions.IisWebSite.UpdateWebsite(IConventionContext context, String webRoot, IisSiteInformation iisSiteName, IisSiteInformation maskedIiSiteName)
at RedGate.Deploy.Agent.Deployment.Conventions.IisWebSite.Apply(IConventionContext context)
at RedGate.Deploy.Agent.Deployment.Conventions.ConventionRunner.<>c__DisplayClassf.<ApplyConventions>b__e(IConvention convention)
at System.Collections.Generic.List`1.ForEach(Action`1 action)
at RedGate.Deploy.Agent.Deployment.Conventions.ConventionRunner.ApplyConventions(IConventionContext context)
at RedGate.Deploy.Agent.Deployment.DeploymentController.Execute(PackageMetadata package, IVariableDictionary variables)
at RedGate.Deploy.Agent.Services.Jobs.DeployPackageJobExecutor.Execute(DeployPackageJob job)
at CallSite.Target(Closure , CallSite , Object , Object )
at RedGate.Deploy.Agent.Services.Jobs.JobRunner.ExecuteJob(IJob job, String& errorMessage, ILogScope additionalLogTarget)

Comments

  • Was suspicious of agent update from today. I uninstalled the agent from the web server and reinstalled from the previously downloaded agent installation package. DM complained about it being out of date, but I re-ran the deployment. That failed as well.

    Restarted the web server and re-ran the deployment after upgrading the agent. Same error...

    Oh my, just when I think this is working. Very discouraging.
  • Looks to be very similar to http://help.octopusdeploy.com/discussio ... om-win7-64

    Check the link to the Octopus site. There seems to be a problem auto-detecting IIS 6 and IIS 7.
  • Hi Steve -

    I've had a look at this problem and it looks like it's quite different to the one that our internal devops team have, which seems to be resolved by restarting the agent process.

    I suspect that your problem is not directly associated with the agent upgrade, since the agent changes in this release should not affect the IIS logic. I think it's instead associated with the restart of the agent process, which will cause it to re-evaluate which versions of IIS are available, and create new COM objects to manage IIS.

    Is it possible that something has changed in your environment since the last time you upgraded/restarted the agent service? Something like installing extra windows features or a windows update might have changed our ability to correctly create IIS websites.

    Can I also check which version of IIS you are using on this agent? I see from the stack trace that we have detected that IIS 7 is running - is this correct?
    David Conlin
    Software Developer
    Deployment Manager
  • There hasn't been anything memorable installed on the machine since the DM processing/agent were installed.

    We're using IIS 7 as far as I can tell.

    How do I check which version of IIS I'm using on the agent?

    Something strange is happening on that machine since the DM/agent upgrade though. After seeing the above link I posted, I checked out the IIS 6 manager that is available on the web server. When it comes up it acts strangely. I compared the way it acted against another of our servers and it doesn't act the same. Here's what it does:

    When I run the IIS 6 manager (%SystemRoot%\system32\inetsrv\InetMgr6.exe) I get a Microsoft Management Console that states:

    C:\Windows\system32\Inetsrv\ii6.msc

    In the 64-bit version of MMC, you can view 4 of the 7 snap-ins in the console file.
    In the 32-bit version of MMC, you can view 3 of the 7 snap-ins in the console file.

    In which version of MMC do you want to view this file?

    64-bit
    32-bit

    Does this everytime IIS 6 manager is run

    This doesn't act this way other web server.
  • The version of IIS you are using should be displayed on the "about" box in IIS manager.

    Note that this also displays the version of windows (and Windows 7's version number is 6.1, so don't be deceived!), and IIS's version number is displayed underneath.

    It sounds like something very funny is going on with the snap-ins to your IIS server - can you find out what your 4 64-bit snap-ins and 3 32-bit snap-ins are?
    David Conlin
    Software Developer
    Deployment Manager
  • I reinstalled IIS 7 on the server.

    I uninstalled DM and the agent that are on the server.

    Reinstalled DM and agent on the server.

    Reconfigured DM for our environment.

    Created new database and web site packages.

    Created release and deployed.

    Same error...

    Dead in the water
  • Checked IIS version via manager and it is: 7.0.6000.16386.
  • After studying the call stack that was generated prior to the error I came upon a realization.

    The problem starts when your code calls it's UpdateWebsite(). From there your code calls it's ChangeHomeDirectory() and soon wanders off to the Microsoft code that inevitably generates the error.

    I thought, why are you guys changing my home directory? I don't want you to.

    Initially when I used DM, I do recall the website home directory being changed, but I added the RedGatePackageDirectoryPath and I'm thinking that stopped that. I've been through so many things trying to get this to work, I just can't recall exactly. All I know is that prior to this failing it was working and the home directory wasn't being changed.

    I went to your website and looked at some of the web site variable options and saw this one:

    RedGateNotAWebSite

    Set this to true and generated another package with a new website package version since you can't redeploy a package with the updated variables --- this is a pain!

    End result --- the website deployed just fine.

    I have a workaround.
Sign In or Register to comment.