Closed ghosttie closed 5 years ago
What's installed on your production environment? Did you install the new hosting bundle?
Yes, I installed the 3.0 hosting bundle and dotnet --info
shows that Microsoft.NETCore.App 3.0.0 and Microsoft.AspNetCore.App 3.0.0 are installed
I ran into same issue: With Framework Dependent publish I was getting 500.0 - ACNM In-Process Handler Load Failure 500.31 - ACNM Failed to find Native Dependencies
After granting IIS_USERS Read/Write permission on the publish folder mapped to IIS site resolved the issue for me.
Thanks @shah-123 but that didn't fix it
I've figured it out!
The main project had project references to other projects that had spaces in their package ids, which somehow kept them from being published correctly (even though there was no error at publish time).
Although there's a simple workaround (remove the spaces) I think this should be fixed, because it worked in previous versions, the error message doesn't lead to a solution, and the package id was set automatically when the project was created so it should have been set to a valid value.
@ghosttie If this is behavior that changed between 2.2 and 3.0, I'd recommend filing an issue in an appropriate repository. I'm uncertain where the issue actually is, maybe with either the dotnet sdk (https://github.com/dotnet/sdk) or nuget (https://github.com/NuGet)?
This doesn't seem like an ANCM issue at all. Even though the error you got was an ANCM error, it's really a red-herring here. I'm going to close this for now, feel free to reopen if you believe there is an issue with AspNetCore.
can you help me what you mean with spaces spaces in their package identifiers
I have the same problem. I was able to recreate it starting with "dotnet new webapi". I published this to IIS and was able to use it. I then run "dotnet add package Microsoft.EntityFrameworkCore.SqlServer" and publish this. Now I get: HTTP Error 500.31 - ANCM Failed to Find Native Dependencies. aspdotnet.zip
I discovered the problem goes away if I'm specific about the --framework. See the deploy.ps1 file in my previous attachment. I was running:
&dotnet publish --output $targetdir --configuration release
The problem goes away if I run this instead:
&dotnet publish --output $targetdir --configuration release --framework netcoreapp3.0
The output of dotnet --list-sdks is: 3.0.100 [C:\Program Files\dotnet\sdk]
@rmegal please file a new issue as this error can have numerous causes. Include your repro app and steps to reproduce the problem.
@icesasoftcorp I believe what @ghosttie meant was that the project referenced other projects with spaces in the name.
I upgraded an ASP.NET Core 2.2 application to 3.0.
It works fine in the development environment, but when I publish it to the test environment I get a
HTTP Error 500.31 - ANCM Failed to Find Native Dependencies
error.The documentation says that this error most commonly means that the
Microsoft.NETCore.App
orMicrosoft.AspNetCore.App
runtime isn't installed but I installed the ASP.NET Core/.NET Core: 3.0 Runtime & Hosting Bundle, and I'm not sure what else I can do.The Event Viewer/stdout logs this:
I don't understand why it's looking under
netcoreapp2.1
for anetcoreapp3.0
application, and why it can't find the dependency even though it's present in therefs
folder.If I manually put that DLL in the folder it's looking for it I get
which I understand even less.
The dotnet --info output is:
I tried installing the SDK but it didn't make any difference.