Windows server 2003x64 and Deployment Manager Agent

Automated deployment for web applications and databases

Postby agr@ida.dk » Thu Jul 03, 2014 7:53 pm

Tried to load C:\\Program Files\\Red Gate\\Deployment Agent\\Agent\\Plugins\\RedGate.D
eploy.SqlServerDbPackage.AgentPlugin\\SQLite.Interop.dll as potential plugin, but
failed.
System.BadImageFormatException: Could not load file or assembly 'file:///C:\\Prog
ram Files\\Red Gate\\Deployment Agent\\Agent\\Plugins\\RedGate.Deploy.SqlServerDbPack
age.AgentPlugin\\SQLite.Interop.dll' or one of its dependencies. The module was e
xpected to contain an assembly manifest.
File name: 'file:///C:\\Program Files\\Red Gate\\Deployment Agent\\Agent\\Plugins\\Red
Gate.Deploy.SqlServerDbPackage.AgentPlugin\\SQLite.Interop.dll'
at System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String cod
eBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark&
stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppre
ssSecurityChecks)
at System.Reflection.RuntimeAssembly.nLoad(AssemblyName fileName, String code
Base, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& s
tackMark, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppres
sSecurityChecks)
at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName as
semblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntr
ospection, Boolean suppressSecurityChecks)
at System.Reflection.RuntimeAssembly.InternalLoadFrom(String assemblyFile, Ev
idence securityEvidence, Byte[] hashValue, AssemblyHashAlgorithm hashAlgorithm,
Boolean forIntrospection, Boolean suppressSecurityChecks, StackCrawlMark& stackM
ark)
at System.Reflection.Assembly.LoadFrom(String assemblyFile)
at RedGate.Deploy.Agent.Plugins.PluginsModule.GetPotentialPluginAssemblies()

WRN: Assembly binding logging is turned OFF.
To enable assembly bind failure logging, set the registry value [HKLM\\Software\\M
icrosoft\\Fusion!EnableLog] (DWORD) to 1.
Note: There is some performance penalty associated with assembly bind failure lo
gging.
To turn this feature off, remove the registry value [HKLM\\Software\\Microsoft\\Fus
ion!EnableLog].

Deployment Agent version 2.4.8.34

-------------------------------------------------------------------------------
- RedGate.Deploy.Agent
-------------------------------------------------------------------------------

Detected plugin IConvention RedGate.Deploy.SqlServerDbPackage.AgentPlugin.DbPack
ageConvention, RedGate.Deploy.SqlServerDbPackage.AgentPlugin, Version=0.0.2.1816
, Culture=neutral, PublicKeyToken=7f465a1c156d4d57 (loaded from C:\\Program Files
\\Red Gate\\Deployment Agent\\Agent\\Plugins\\RedGate.Deploy.SqlServerDbPackage.Agent
Plugin\\RedGate.Deploy.SqlServerDbPackage.AgentPlugin.dll)
Started job queue
System.Security.Cryptography.CryptographicException: Object already exists.

at System.Security.Cryptography.CryptographicException.ThrowCryptographicExce
ption(Int32 hr)
at System.Security.Cryptography.X509Certificates.X509Utils._ExportCertificate
sToBlob(SafeCertStoreHandle safeCertStoreHandle, X509ContentType contentType, In
tPtr password)
at System.Security.Cryptography.X509Certificates.X509Certificate.ExportHelper
(X509ContentType contentType, Object password)
at System.Security.Cryptography.X509Certificates.X509Certificate.Export(X509C
ontentType contentType)
at RedGate.Deploy.Shared.Security.CertificateEncoder.ToBase64String(X509Certi
ficate2 certificate, X509ContentType exportType)
at RedGate.Deploy.Shared.Configuration.AgentConfiguration.set_AgentCertificat
e(X509Certificate2 value)
at RedGate.Deploy.Shared.Configuration.AgentConfiguration.GenerateNewCertific
ate()
at RedGate.Deploy.Shared.Configuration.AgentConfiguration.get_AgentCertificat
e()
at RedGate.Deploy.Agent.Services.AgentServiceHostStarter.SetupCredentials(Ser
viceHost host)
at RedGate.Deploy.Shared.Services.ServiceHostStarter.LaunchServiceHost(Uri ad
dress, ServiceMetadata service)
at RedGate.Deploy.Shared.Services.ServiceHostStarter.Start()
at RedGate.Deploy.Agent.Commands.RunAgentCommand.Start()
at RedGate.Deploy.Shared.Startup.Host.InternalRunConsole(Action execute, Acti
on shutdown)
Command RedGate.Deploy.Agent.Commands.RunAgentCommand failed
System.Security.Cryptography.CryptographicException: Object already exists.


Server stack trace:
at System.Security.Cryptography.CryptographicException.ThrowCryptographicExce
ption(Int32 hr)
at System.Security.Cryptography.X509Certificates.X509Utils._ExportCertificate
sToBlob(SafeCertStoreHandle safeCertStoreHandle, X509ContentType contentType, In
tPtr password)
at System.Security.Cryptography.X509Certificates.X509Certificate.ExportHelper
(X509ContentType contentType, Object password)
at System.Security.Cryptography.X509Certificates.X509Certificate.Export(X509C
ontentType contentType)
at RedGate.Deploy.Shared.Security.CertificateEncoder.ToBase64String(X509Certi
ficate2 certificate, X509ContentType exportType)
at RedGate.Deploy.Shared.Configuration.AgentConfiguration.set_AgentCertificat
e(X509Certificate2 value)
at RedGate.Deploy.Shared.Configuration.AgentConfiguration.GenerateNewCertific
ate()
at RedGate.Deploy.Shared.Configuration.AgentConfiguration.get_AgentCertificat
e()
at RedGate.Deploy.Agent.Services.AgentServiceHostStarter.SetupCredentials(Ser
viceHost host)
at RedGate.Deploy.Shared.Services.ServiceHostStarter.LaunchServiceHost(Uri ad
dress, ServiceMetadata service)
at RedGate.Deploy.Shared.Services.ServiceHostStarter.Start()
at RedGate.Deploy.Agent.Commands.RunAgentCommand.Start()
at RedGate.Deploy.Shared.Startup.Host.InternalRunConsole(Action execute, Acti
on shutdown)

Exception rethrown at [0]:
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccess(Task task)
at RedGate.Deploy.Shared.Startup.CommandProcessor.<ProcessAsync>d__4.MoveNext
()
Scheduler disposed.
Exited job queue
agr@ida.dk
 
Posts: 7
Joined: Tue Jul 01, 2014 6:53 pm

Postby Mike Upton » Sun Jul 06, 2014 8:55 am

That log indicates that you're not running the latest version of the Deployment Agent:
Deployment Agent version 2.4.8.34

You would normally be able to automatically update the agents from the Deployment Manager web interface, but unfortunately that doesn't work when the Agent service isn't running. Instead, you'll need to perform a manual upgrade of the agent. You can simply get the agent installer .msi from the Tools page of your own Deployment Manager server (http://{your_deployment_manager_server_address}:{port}/downloads/agentinstaller) and run it on the machine in question.

Upgrading the Agent to 2.4.12.1 should fix the problem.
Mike Upton

Project Manager - SQL Compare|Data Compare|Comparison SDK
Redgate Software Ltd.
Mike Upton
 
Posts: 190
Joined: Wed May 11, 2011 8:04 am
Location: Redgate

Postby agr@ida.dk » Mon Jul 07, 2014 11:05 am

Upgrading the agent

And changing permissions on the c:\\document and settings\\all users\\application data\\Microsoft\\crypto\\rsa\\machinekeys solved the problem - without changing the permssions it still failed.

But in all fairness I've also 2003 x86 where it works without changing anything so it might be some quirky thing in an old installation.

The important part is that it's working now.
agr@ida.dk
 
Posts: 7
Joined: Tue Jul 01, 2014 6:53 pm

Previous

Return to Deployment Manager

Who is online

Users browsing this forum: No registered users and 0 guests