Using Windows it is possible to enable Fusion assembly logs via registry (https://techcommunity.microsoft.com/t5/iis-support-blog/fusion-log-viewer-fuslogvw-exe/ba-p/784396) to be saved on local hard drive.
My .NET Core 3.1 application is working properly on Windows. On Docker container based on Linux I'm getting randomly "Could not load file or assembly" for some assemblies, which actually are available in proper place in build directory and for some runs they work properly.
Sample assembly error:
Could not load file or assembly 'Renci.SshNet, Version=2016.1.0.0, Culture=neutral, PublicKeyToken=1cee9f8bde3db106'. The system cannot find the file specified.
I would like to enable debug logging related to assemblies to find a root cause of described issue.
Can I enable anyhow fusion logs on Linux?
Related
I am using PdfSharpCore version 1.3.40 in a MVC ASP.Net netcoreapp2.1 and it works perfectly on my windows localhost, but when I publish it on a server Linux running Apache the follow exception occurs:
Could not load file or assembly 'PdfSharpCore, Version=1.3.40.0, Culture=neutral, PublicKeyTo ken=null'. The system cannot find the file specified.
I already checked that the PdfSharpCore dll is there, but the system couldn't find it.
Does anyone know what's going on?
We managed to solve the problem, we were forgetting to replace the .deps.json file that contains the dependencies with the new PdfSharpCore.dll dll included in the project. Solved!
I am trying work with the VMWare SDK to create a Windows service in C# & .NET that automates launching and stopping virtual machines in the VMWare Workstation. I have downloaded the SDK and referenced the necessary dll files in my project.
VimClient c = new VimClientImpl();
ServiceContent sc = c.Connect(serverURL);
UserSession us = c.Login(username, password);
IList<EntityViewBase> vmList = c.FindEntityViews(typeof(VirtualMachine), null, null, null);
I'm attempting to run a basic example but when attempting to connect to the service, I encounter the following exception: "Could not load file or assembly 'VMware.Binding.WsTrust, Version=12.2.0.3593, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified."
When running as a Console Application in .NET Core, I get a similar exception: "Could not load file or assembly 'VMware.System.Private.ServiceModel".
I have tried copying over the runtime dll's from the nuget packages in my user folder and modifying my .csproj file to include these dll's, but I am still encountering the exceptions.
I am using .NET Framework 4.7.2. and my Target OS is Windows 10.
Assemblies added:
InternalVimService50.Wcf
InternalVimService70.Wcf
InventoryService55.Wcf
VimService.dll
VMware.Vim.dll
VmWare.Binding.Wcf
Stack Trace: StackTrace = " at
VMware.Vim.VimClientImpl.CreateClientChannel()\r\n at
VMware.Vim.VimClientImpl.Connect()\r\n at
VMware.Vim.VimClientImpl.Connect(String serviceUrl)\r\n at
VMWareServiceTest.Service1.OnElapsedTime(Object source, ElapsedEventArgs e) in C:\\Users\...
Exception Message:"Could not load file or assembly 'VMware.Binding.WsTrust, Version=12.2.0.3593, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified."
Any help would be greatly appreciated, thank you.
(First post on SO, but regular user of all the wonderful wisdom)
I just had this same issue trying to learn how to interact with vSphere using .Net.
Solved it by building vsphere-ws\dotnet\cs\samples\VMware.Binding.WsTrust from the VMware vSphere SDK, and then adding a refrerence to the resulting dll to my project.
I just loaded the Samples2012.sln in Visual Studio and build that particular project.
Involved versions:
PowerCLI 12.0.0 build 15947286 (Not sure if needed, but this is where I referenced VMware.Vim.dll)
VMware vSphere SDK 6.7U3 (6.7.0-14379537)
Visual Studio 2019 (16.8.2)
.NET Framework 4.8
Windows 8.1
Hopes this helps.
I'm using nuget package IBM.Data.DB2.Core version 1.3.0.100 dll to connect DB2 database from Azure functions with AzureFunctionsVersion V2. Application builds successfully.
When I run the application and hit it with Postman I get the exception:
System.Private.CoreLib: Exception while executing function: Personal-GetAgencyDownload. AgencyDownload: Could not load file or assembly 'IBM.Data.DB2.Core, Version=1.2.2.201, Culture=neutral, PublicKeyToken=7c307b91aa13d208'. Could not find or load a specific file. (Exception from HRESULT: 0x80131621). System.Private.CoreLib: Could not load file or assembly 'IBM.Data.DB2.Core, Version=1.2.2.201, Culture=neutral, PublicKeyToken=7c307b91aa13d208'.
I see the 1.3.0.100 package, there isn't any other package. Why is it looking for 1.1.1.201 in runtime?
Know this is a little late, but just in case others have this issue with the latest version of IBM.Data.DB2.Core (version 3.1.0.300 at time of writing) for me it was due to the Azure function platform defaulting to 32bit, and the IBM dll (or one of its dependencies) required 64bit. Changing the platform setting to 64 bit resolved this error.
You can find the setting under configuration > general settings in the azure portal.
This could happen if you have the IBM.DataDB2.dll file lying around in directories other than the DB2 client install location. This could have happened without your knowledge where Visual Studio copies the necessary dll into the bin directory of the project.
IBM.Data.DB2.dll has dependencies on other client libraries in DB2 Client installation. So refer the DLL from the DB2 Client installation location only and do not save a local copy in the application directory.
Go to the reference in the project and set Copy local to false for DB2 dlls, referencing directly the ones from the DB2 client setup.
I am new in asp.net core and azure.
I have small web app on asp.net core mvc, and I want to publish this project to azure. Locally the project work fine, but when I try to build the project through the console on azure, this error appears -
Unhandled Exception: System.IO.FileLoadException: Could not load file
or assembly 'Microsoft.Extensions.Identity.Core, Version=2.1.6.0,
Culture=neutral, PublicKeyToken=adb9793829ddae60'. The located
assembly's manifest definition does not match the assembly reference.
(Exception from HRESULT: 0x80131040) at
program.Startup.ConfigureServices(IServiceCollection services)
When i try to open across his link I see this:
An error occurred while starting the application.
.NET Core 4.6.27129.04 X86 v4.0.0.0 | Microsoft.AspNetCore.Hosting version 2.1.1-rtm-30846 | Microsoft Windows 10.0.14393 | Need help?
And my question is: What I need to do, to fix this error ?
I'm getting a very similar error on my core 2.1 site published as an Azure App Service:
System.Reflection.ReflectionTypeLoadException: Unable to load one or
more of the requested types. Could not load file or assembly
'Microsoft.Extensions.Identity.Core, Version=2.1.6.0, Culture=neutral,
PublicKeyToken=adb9793829ddae60'. The system cannot find the file
specified.
It was running perfectly until it suddenly stopped working. I honestly don't know why the issue started but in the mean time I solved it by changing the "Deployment Mode" to "Self-Contained" on the publish profile settings.
To get there just right click your website, click on publish, select your profile and click on Configure. Then click on Settings and change the "Deployment Mode". That will add all the ddl's locally and get your site working again.
Visual Studio publish profile
Good day. I have developed an application which works successfully on my local machine but I have run into a problem when moving out to production.
The error is as follows:
System.IO.FileNotFoundException: Could not load file or assembly 'IBM.XMS.Admin, Version=2.5.0.0, Culture=neutral, PublicKeyToken=d2666ab12fca862b' or one of its dependencies. The system cannot find the file specified.
File name: 'IBM.XMS.Admin, Version=2.5.0.0, Culture=neutral, PublicKeyToken=d2666ab12fca862b'
I understand where this file is - C:\Prog... - and my .Net application is simply referencing IBM.XMS.dll which works. It's when I deploy and run I get the error above.
I used the following installation instructions and restarted the system too:
http://publib.boulder.ibm.com/infocenter/wmqv7/v7r0/topic/com.ibm.mq.csqzav.doc/un10290_.htm
Your application is built with XMS v2.5. Do you have XMS v2.5 (shipped with MQ v7.5 client) installed on the other machine?
check out Microsoft's fusion log viewer and see how you get on.
In my experience when I see this message the keywords are or one of its dependencies. The fusion log may help you find out which one.