Could not load file or assembly 'DragnetControlsLib

If you are having a problem using Fortress, post a message here.

Moderator: SourceGear

Post Reply
tademet
Posts: 6
Joined: Tue Jul 07, 2009 7:45 am

Could not load file or assembly 'DragnetControlsLib

Post by tademet » Tue Jul 07, 2009 8:01 am

I am getting an error when attempting to run the Web Admin client.
I am running Vista 64, IIS 7, and Fortress 2 beta 2

Server Error in '/VaultService' Application.
--------------------------------------------------------------------------------

Could not load file or assembly 'DragnetControlsLib, Version=2.0.0.18655, Culture=neutral, PublicKeyToken=null' or one of its dependencies. An attempt was made to load a program with an incorrect format.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.BadImageFormatException: Could not load file or assembly 'DragnetControlsLib, Version=2.0.0.18655, Culture=neutral, PublicKeyToken=null' or one of its dependencies. An attempt was made to load a program with an incorrect format.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:


[BadImageFormatException: Could not load file or assembly 'DragnetControlsLib, Version=2.0.0.18655, Culture=neutral, PublicKeyToken=null' or one of its dependencies. An attempt was made to load a program with an incorrect format.]
System.Reflection.Assembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection) +0
System.Reflection.Assembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection) +43
System.Reflection.Assembly.InternalLoad(AssemblyName assemblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection) +127
System.Reflection.Assembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection) +142
System.Reflection.Assembly.Load(String assemblyString) +28
System.Web.Configuration.CompilationSection.LoadAssemblyHelper(String assemblyName, Boolean starDirective) +46

[ConfigurationErrorsException: Could not load file or assembly 'DragnetControlsLib, Version=2.0.0.18655, Culture=neutral, PublicKeyToken=null' or one of its dependencies. An attempt was made to load a program with an incorrect format.]
System.Web.Configuration.CompilationSection.LoadAssemblyHelper(String assemblyName, Boolean starDirective) +613
System.Web.Configuration.CompilationSection.LoadAllAssembliesFromAppDomainBinDirectory() +203
System.Web.Configuration.CompilationSection.LoadAssembly(AssemblyInfo ai) +105
System.Web.Compilation.BuildManager.GetReferencedAssemblies(CompilationSection compConfig) +178
System.Web.Compilation.BuildProvidersCompiler..ctor(VirtualPath configPath, Boolean supportLocalization, String outputAssemblyName) +54
System.Web.Compilation.ApplicationBuildProvider.GetGlobalAsaxBuildResult(Boolean isPrecompiledApp) +232
System.Web.Compilation.BuildManager.CompileGlobalAsax() +52
System.Web.Compilation.BuildManager.EnsureTopLevelFilesCompiled() +337

[HttpException (0x80004005): Could not load file or assembly 'DragnetControlsLib, Version=2.0.0.18655, Culture=neutral, PublicKeyToken=null' or one of its dependencies. An attempt was made to load a program with an incorrect format.]
System.Web.Compilation.BuildManager.ReportTopLevelCompilationException() +58
System.Web.Compilation.BuildManager.EnsureTopLevelFilesCompiled() +512
System.Web.Hosting.HostingEnvironment.Initialize(ApplicationManager appManager, IApplicationHost appHost, IConfigMapPathFactory configMapPathFactory, HostingEnvironmentParameters hostingParameters) +729

[HttpException (0x80004005): Could not load file or assembly 'DragnetControlsLib, Version=2.0.0.18655, Culture=neutral, PublicKeyToken=null' or one of its dependencies. An attempt was made to load a program with an incorrect format.]
System.Web.HttpRuntime.FirstRequestInit(HttpContext context) +8894031
System.Web.HttpRuntime.EnsureFirstRequestInit(HttpContext context) +85
System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context) +333




--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.50727.4016; ASP.NET Version:2.0.50727.4016

jeremy_sg
Posts: 1821
Joined: Thu Dec 18, 2003 11:39 am
Location: Sourcegear
Contact:

Re: Could not load file or assembly 'DragnetControlsLib

Post by jeremy_sg » Tue Jul 07, 2009 8:48 am

Since you're running the beta 2, here's some questions for you.

1. Did you install the 64 bit server installer?

2. The easiest way to get a "BadImageFormatException" is to have the 32bit framework try to load a 64bit install. You should try to run:

Code: Select all

"C:\Windows\Microsoft.NET\Framework64\v2.0.50727\aspnet_regiis.exe" -i
That will register the 64bit framework as the handler for ASP.NET.
Subscribe to the Fortress/Vault blog

tademet
Posts: 6
Joined: Tue Jul 07, 2009 7:45 am

Re: Could not load file or assembly 'DragnetControlsLib

Post by tademet » Tue Jul 07, 2009 9:03 am

1. Yes
2. Get an error when I try to run it. 0x80004005 Unspecified error. Also it says
Note: This utility has limited capabilities on the Windows Vista operating
system. It is recommended that you use the "Turn on or off Windows features"
option of the "Programs" component of Control Panel to install or remove
ASP.NET. It is also recommended that you use the IIS Manager component or the
Appcmd.exe tool to configure ASP.NET applications.

jeremy_sg
Posts: 1821
Joined: Thu Dec 18, 2003 11:39 am
Location: Sourcegear
Contact:

Re: Could not load file or assembly 'DragnetControlsLib

Post by jeremy_sg » Tue Jul 07, 2009 10:21 am

Are you running the command from the Administrator command prompt?

Also, does Fortress work after the command is run?
Subscribe to the Fortress/Vault blog

tademet
Posts: 6
Joined: Tue Jul 07, 2009 7:45 am

Re: Could not load file or assembly 'DragnetControlsLib

Post by tademet » Tue Jul 07, 2009 10:33 am

The aspnet_regiis did work once I ran it as adminstrator.

Fortress does not work after the command has been run.

jeremy_sg
Posts: 1821
Joined: Thu Dec 18, 2003 11:39 am
Location: Sourcegear
Contact:

Re: Could not load file or assembly 'DragnetControlsLib

Post by jeremy_sg » Tue Jul 07, 2009 10:43 am

Are you still getting the Bad Image exception?

It might be worth trying some of these things:

1. Do an iisreset on the server.
2. Reinstall the server
Subscribe to the Fortress/Vault blog

tademet
Posts: 6
Joined: Tue Jul 07, 2009 7:45 am

Re: Could not load file or assembly 'DragnetControlsLib

Post by tademet » Tue Jul 07, 2009 1:23 pm

I am still getting the BadImage error.

I did the iisreset and still got the BadImage error.

I un-installed the Fortress Server and re-installed it and got the same error.

I noticed in the notes for Fortress 2 Beta 2 that the server had to have .Net 3.5 but the site is set up to run under 2.0. I have tried changing it tot 3.5 but I do not have the option even though 3.5 is installed on the machine.

jeremy_sg
Posts: 1821
Joined: Thu Dec 18, 2003 11:39 am
Location: Sourcegear
Contact:

Re: Could not load file or assembly 'DragnetControlsLib

Post by jeremy_sg » Tue Jul 07, 2009 1:42 pm

Hrm...

That's weird.

There isn't a 3.5 entry in the dropdown, because the core runtime engine of the .Net Framework hasn't changed since 2.0. It's only the libraries that come along with the framework that are updated.

You did make sure to use the Framework64 version and not the one that is in Framework, right? Sorry to ask obvious questions, but I'm running low on ideas.
Subscribe to the Fortress/Vault blog

tademet
Posts: 6
Joined: Tue Jul 07, 2009 7:45 am

Re: Could not load file or assembly 'DragnetControlsLib

Post by tademet » Tue Jul 07, 2009 2:03 pm

Yep used the Framework64.
C:\Windows\system32>"C:\Windows\Microsoft.NET\Framework64\v2.0.50727\aspnet_regiis.exe" -lv
2.0.50727.0 C:\Windows\Microsoft.NET\Framework64\v2.0.50727\aspnet_isapi.dll
1.1.4322.0 C:\Windows\Microsoft.NET\Framework\v1.1.4322\aspnet_isapi.dll

jeremy_sg
Posts: 1821
Joined: Thu Dec 18, 2003 11:39 am
Location: Sourcegear
Contact:

Re: Could not load file or assembly 'DragnetControlsLib

Post by jeremy_sg » Tue Jul 07, 2009 3:21 pm

We have a VM that can reproduce this issue with beta 2 (which didn't happen in beta 1). We'll track this down and post back to this thread when we have an answer. Thank you for the bug report, and for spending so much time trying to get the beta running.
Subscribe to the Fortress/Vault blog

jeremy_sg
Posts: 1821
Joined: Thu Dec 18, 2003 11:39 am
Location: Sourcegear
Contact:

Re: Could not load file or assembly 'DragnetControlsLib

Post by jeremy_sg » Wed Jul 08, 2009 2:29 pm

We've figured out the problem. In the Vault App Pool's Advanced settings dialog, you'll need to set "Enable 32-bit applications" to false. This mis-named setting actually means "die if I see a 64-bit application". The final release will not have this problem. Thanks again for your patience.
Subscribe to the Fortress/Vault blog

tademet
Posts: 6
Joined: Tue Jul 07, 2009 7:45 am

Re: Could not load file or assembly 'DragnetControlsLib

Post by tademet » Thu Jul 09, 2009 7:43 am

Yep, that worked. Thank you for your help.

asills
Posts: 95
Joined: Tue Jan 25, 2005 5:05 pm

Re: Could not load file or assembly 'DragnetControlsLib

Post by asills » Sun Sep 27, 2009 6:24 pm

FWIW, I had 1.1.4.18402 64 bit installed on my server 2008 box and upgraded to 2.0.1.18729 and this problem popped up. So it looks like the upgrade isn't taking care of this problem.

mikecausi
Posts: 20
Joined: Wed Mar 03, 2010 12:48 pm

Re: Could not load file or assembly 'DragnetControlsLib

Post by mikecausi » Wed Mar 03, 2010 12:55 pm

Is this still a known problem? I just installed the 64-bit server on Windows 2003 64-bit. It previsously had IIS and ASP.NET 1.1, 2.0 and 3.5 running. Using Visual Studio 2003, 2005,2008.

What else could be missing to get this to run?

hesed4him
Posts: 1
Joined: Thu Mar 11, 2010 10:58 pm

Re: Could not load file or assembly 'DragnetControlsLib

Post by hesed4him » Thu Mar 11, 2010 10:59 pm

FYI, having the same issue with "Dragnet" in version 2.0.3.18802.

Post Reply