Logged into a customer environment today to check logs and just generally do an inspection, only to notice some tasks had failed in one application.
Application is written in c# .net v4 running inside of IIS and exports to Sharepoint 2007.
I can't be 100% sure if .net or SharePoint is the culprit. These are the errors I got:
Task Failed: Server was unable to
process request. ---> Could not find
file 'C:\Windows\TEMP\qbckfur1.dll'.
Export 26.05.2011 15:00:21 Failure
Task Failed: Server was unable to
process request. ---> Could not find
file 'C:\Windows\TEMP\2shjg2xb.dll'.
Export 26.05.2011 15:30:13 Failure
Task Failed: Server was unable to
process request. ---> Could not find
file 'C:\Windows\TEMP\b7utp199.dll'.
Export 26.05.2011 16:00:15 Failure
Task Failed: Server was unable to
process request. ---> Could not find
file 'C:\Windows\TEMP\ozr2umkm.dll'.
Does this look familiar to anyone?
This is a problem with XmlSerialization (beleive it or not). I ran into this with a custom ASP.NET MVC app. Apparently, when you call Serialize or Deserialize on types marked as "Serializable", .NET will generate an assembly on-the-fly to support the serialization and it attempts to write that assembly into 'c:\windows\temp'.
Even if Everyone has full control access to that directory I have still seen this occur when running an app from within an IIS App Pool. Especially in applications that has a lot of serialization activity.
If this sounds like your problem, the solution is to "pre-compile" the Serialization assembly and include it in your application with sgen, part of the Windows SDK.
This post highlights a similar issue: Serialization issue on MSDN Social
Here is the MSDN article on the tool: sgen reference
Final Note: There is a separate version of the Tool for .NET 4.0 so make sure you are using the correct version when generating your assembly.
Related
I have a .Net Core 3.1 WPF app. It needs to connect to a service and pull/push data to that service. The app executable works without any error message. However, when I publish the Self Contained app and make it a single exe file, It is not able to connect to the service and throws an exception with the following message.
Could not load type 'System.Dynamic.IInvokeOnGetBinder' from assembly netstandard, Version=2.1.0.0, Culture=neutral
What may cause this exception?
This must be a bug on the Microsoft side. I went ahead and unchecked the Trim unused assemblies and the app starts working. Although this outputted a bigger executable file, Trimming seems to be removing too much if enabled.
I'm building a website in VS2015 (C# using Razor)
I see many posts where people say that they receive this error on their server, but not localhost - my issue is the opposite. I'm seeing this error in every *.ashx file preamble in this specific Website only while running Localhost on my development machine:
ASP.Net runtime error: Loading this assembly would produce a different grant set from other instances (Exception from: HRESULT 0x80131401)
This error prevents me from using Intellisense in the file - and I really need it for this next handler.
What I've Determined: - The issue is specific to this Website. I have other websites that do not produce this error, so there isn't a need to modify registry or change PC configurations.
What I've tried:
IISReset (Restart PC) [*before I realized problem was local]
Changing Registry by adding LoadingOptimizer DWORD [*before I realized problem was local]
Compared XML of a working Web.config file. (Other than assembly differences I played around with other differences and still nothing)
Any suggestions?
Am using Quartz.Net to run a couple of scheduled jobs within a C# windows service hosted by Topshelf. I have started encountering a situation where the service does not run from source code and upon investigate I found the following error:
The debugger could not locate the source file 'c:\Program Files (x86)\Jenkins\workspace\Quartz.NET\src\Quartz\JobBuilder.cs'.
Any body know how to sort this out.
I'm working on a Windows 10 Store Windows Universal app using Visual Studio 2015 Community, c#, and XAML. It is decompressing a compressed file and displaying images found therein.
The build provides 0 warnings.
The debug version runs fine regardless of input file size.
The release version runs fine with typical input file sizes.
For large input file sizes (~100 1 megapixel images), the release build crashes consistently with 'Unhandled exception at 0x55E9A305 (Windows.UI.Xaml.dll) in appname.exe: 0xC000027B: An application-internal exception has occurred (parameters: 0x127DC468, 0x00000005).'
The crash occurs when the user tries to display the second image. All decompression is complete and all the bitmaps have been created by this time.
I've fiddled with the Build settings and narrowed down the difference to the option 'Compile with .NET Native Tool chain'. If that option is checked, the application crashes. If that option is unchecked, the application runs fine.
All told, the application is using about 400 MB of heap so although not small it isn't near the capacity of the machine.
"So uncheck the option!", I hear you cry. Unchecking the box leads to the certification failure shown below:
FAILED
Supported APIs
• Error Found: The supported APIs test detected the following errors:
-API OpenSemaphore in api-ms-win-core-synch-l1-1-0.dll is not supported for this application type. System.Threading.dll calls this API.
-API CreateSemaphore in api-ms-win-core-kernel32-legacy-l1-1-0.dll is not supported for this application type. System.Threading.dll calls this API.
-API ExecuteAssembly in uwphost.dll is not supported for this application type. StupidTest.exe calls this API.
-API DllGetActivationFactory in uwphost.dll is not supported for this application type. StupidTest.exe has an export that forwards to this API.
An empty project suffers the same failure if Compile .Net Native tool chain is not selected.
So my questions:
Must Universal Apps use Compile .Net Native tool chain?
Is there any documentation on the meanings of the parameters in the internal exception or somewhere else I can turn to troubleshoot?
In short, any advice on getting out the "It doesn't work if selected, but you must select it to get certified" dilemma I find myself in?
I struggled with this issue also for the past few days, and I've found the answer!
So if you haven't updated Visual Studio 2015 to Update 1, do it. Because this error is a bug in the compiler and after the update you will be able to build the project with the Compile .Net Native tool chain option selected.
And yes, those four errors that the WACK tool picks up, is because of compiling your project without checking the .Net Native tool chain option in the Build menu of the Package.appxmanifest file.
I am using Entity Framework in an application i am working on, however when i try to launch it from another user's machine, while trying to load the EDM i get an Exception stating that the request for the AspNetHostingPermission has failed. The assemblies are located on a network share.
The assemblies are not signed and as far as i know, since 3.5 SP1, assemblies on network shares run under full trust. What is going wrong?
EDIT: It seems this is a general trust issue, considering that i also got an error about ReflectionPermission.
This is definitely a trust issue. Other people have reported the same error when running from a network share.