Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Applications missing DLL Files after automatic update #102804

Closed
FunLow opened this issue May 29, 2024 · 4 comments
Closed

Applications missing DLL Files after automatic update #102804

FunLow opened this issue May 29, 2024 · 4 comments

Comments

@FunLow
Copy link

FunLow commented May 29, 2024

Good Morning,

Description
some month ago we enabled the automatic updates on virtual machines in our environment to receive continous security patches for the several .NET versions (.NET 6, .NET 7, .NET 8) used by our applications. For that we used the suggested method announced some while ago in the Blog.
For scheduling the updates we are using Windows Update configured on the virtual machine as well as the Azure Update Manager.

Now yesterday (28.05.2024) when the new update for the .NET has been released again a lot of API's are running into errors pointing out that certain dll files are missing. The API's in general were still running and also reachable (e.g swagger / health endpoints). But in case there were calls that involved more logic we faced a lot of errors. Some examples i found related to missing dlls were:

System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation.
---> System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.AspNetCore.Authentication.OAuth, Version=6.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60'. The system cannot find the file specified.
File name: 'Microsoft.AspNetCore.Authentication.OAuth, Version=6.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60
DirectoryNotFoundException: Could not find a part of the path 'C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App\6.0.30\Microsoft.AspNetCore.App.deps.json

I know that these dependencies are part of the update but im wondering why they are not reloaded the same way as its handled with .NET. This seems to me like a bug as there seems to be a missing reload of the runtime files or the applications only partially reload their dependencies. Expecially it seems to be an issue with dependencies located in the AspNetCore Namespace. This is part of the update but isn't reloaded by the applications what sounds to me like something is missing in that place.

Is there any way to prevent this behaviour ?
Are there any other ways to receive updates without having such an impact on productive applications ?

Thanks in advance.

@dotnet-issue-labeler dotnet-issue-labeler bot added the needs-area-label An area label is needed to ensure this gets routed to the appropriate area owners label May 29, 2024
@dotnet-policy-service dotnet-policy-service bot added the untriaged New issue has not been triaged by the area owner label May 29, 2024
@huoyaoyuan huoyaoyuan added area-Setup and removed needs-area-label An area label is needed to ensure this gets routed to the appropriate area owners labels May 29, 2024
@huoyaoyuan
Copy link
Member

It looks like your "base" framework (Microsoft.NET.App) and ASP.NET framework (Microsoft.AspNetCore.App) are messed up by the update.

Can you run dotnet --info on the machine and see what it outputs?

After update of this month, I have both 6.0.30 and 6.0.31 on my machine.

@FunLow
Copy link
Author

FunLow commented May 29, 2024

@huoyaoyuan
This is what the current state is looking like on one of the virtual machines:

global.json file:
  Not found

Host:
  Version:      6.0.31
  Architecture: x64
  Commit:       e2ca2f8a1c

.NET SDKs installed:
  No SDKs were found.

.NET runtimes installed:
  Microsoft.AspNetCore.App 6.0.31 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
  Microsoft.NETCore.App 6.0.31 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]

Download .NET:
  https://aka.ms/dotnet-download

Learn about .NET Runtimes and SDKs:
  https://aka.ms/dotnet/runtimes-sdk-info

But as far as i remember this is intended by the Auto update behaviour for dotnet. It was announced not that much time ago. So its not messed up actually its only trying to still run the old version thats not available anymore as the auto update is removing the previous version.

@jkotas
Copy link
Member

jkotas commented May 29, 2024

Related/duplicate of #60144, #100452, #101231.

@FunLow
Copy link
Author

FunLow commented Jun 3, 2024

@jkotas Thanks a lot. Thats seems to be exactly the issue(s) im referring to.

@FunLow FunLow closed this as not planned Won't fix, can't repro, duplicate, stale Jun 3, 2024
@dotnet-policy-service dotnet-policy-service bot removed the untriaged New issue has not been triaged by the area owner label Jun 3, 2024
@github-actions github-actions bot locked and limited conversation to collaborators Jul 4, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants