Skip to content

Different Behavior during ASPNET Core upgrade (MSI install vs Windows Update install) #41377

Closed

Description

@RomBrz

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

Last week i discovered that i could update the ASPNET Core versions on servers using WSUS updates and configure to deliver the ASPNET Core updates to help me managing 30+ servers.
Happen to the WSUS update doesn't make the server at same level comparing with a "Stand alone Host Bundle Install".

I have two servers "twins", with same ASPNET Core versions installed on both.
Server 1 i downloaded the Hosting Bundle packages (https://dotnet.microsoft.com/en-us/download/dotnet)
Server 2 i installed all the Windows Updates available (WSUS configured using https://devblogs.microsoft.com/dotnet/net-core-updates-coming-to-microsoft-update/)

Server1 after installing manually:
.NET Core Runtimes:
6.0.4 x86
6.0.4 x64
5.0.16 x86
5.0.16 x64
3.1.24 x86
3.1.24 x64

ASP.NET Core Runtimes:
6.0.4 x86
6.0.4 x64
5.0.16 x86
5.0.16 x64
3.1.24 x86
3.1.24 x64

.NET Core Runtime & Hosting Bundles:
3.1.24
6.0.4
5.0.16

Server2 after WSUS install:
.NET Core Runtimes:
6.0.3 x86
6.0.3 x64
5.0.16 x86
5.0.16 x64
3.1.24 x86
3.1.24 x64

ASP.NET Core Runtimes:
6.0.3 x86
6.0.3 x64
5.0.16 x86
5.0.16 x64
3.1.24 x86
3.1.24 x64

.NET Core Runtime & Hosting Bundles:
3.1.23
6.0.4
5.0.15

Seems like either the Hosting Bundle are update or the Runtime are updates.
3.1.24 and 5.0.16 updated the runtimes, but not the Hosting Bundle
6.0.4 updated the Hosting Bundle, but not the runtimes.

After reboot, and checking with Windows Update again, no updates are found.

Expected Behavior

The WSUS/Windows Update of the ASPNET Core should deliver the same "updated version" that the intall of the stand alone Hosting Bundle package.

Steps To Reproduce

No response

Exceptions (if any)

No response

.NET Version

all versions

Anything else?

No response

Activity

  1. added
    feature-installers
    area-infrastructure
    on Apr 26, 2022
  2. wtgodbe commented on Apr 26, 2022

    @wtgodbe
    Member

    @jamshedd do we know what version(s) of the hosting bundle are now available on WSUS?

    I just confirmed that installing the 6.0.3 Hosting Bundle followed by the 6.0.4 one will leave the 6.0.4 runtimes on your machine as expected, so I'm surprised to see the WSUS machine w/ the 6.0.4 Hosting Bundle but 6.0.3 runtimes

  3. jamshedd commented on Apr 27, 2022

    @jamshedd
    Member

    The removal of the older 6.0.3 runtime should not have anything to do with whether the hosting bundle was installed via WSUS or manually. Removal is of the older installers is handled by our bundle and the same bundle is executed in both cases. The removal of hte older runtime (or lack thereof) is likely a function of what else is on the machine (for e.g. VS) that might be referencing the older installer, or what app or service might have been running and locked files.

    Adding @csnellgrove1-zz to confirm.

  4. RomBrz commented on Apr 27, 2022

    @RomBrz
    Author

    I did more tests after this post.
    Explaining better:
    Server1: Installed manually the hosting bundle
    Server2: Installed with WSUS -> Installing the 04/2022 patches (Windows, DotNet Framework, DotNet Core) -> DotNet 6.0.4 installation FAILED
    Server3: Installed with WSUS -> Installing the 04/2022 patches (Windows, DotNet Framework, DotNet Core) -> DotNet 6.0.4 installation OK

    Seems like the Server2 has some problem installing all the patches together. After reboot, the patch didn't show (Windows Update says that everything is up to date). (And the information appears like the initial post) I tried manually installing the 6.0.4 Hosting Bundle but didn't work. After some "good" time trying to solve what's wrong, because no matter what i did, i could not install the 6.0.4 (but could install the 6.0.3 after removing everything about 6.0.*), (ever tried install 6.0.4 after reinstall 6.0.3 but didn't work either) i reinstalled the 6.0.3, checked for updates, Windows Update found the 6.0.4 and installed OK. So seems like that the crash during the first Windows Update install broke and lock the server to only accept the 6.0.4 with WU.

    About the Server3, it received the same patches that Server2 received, but installed all patches without problem. The result was that the server ends with the same components that Server2 (after all i posted above).

    Both servers updated The 3.1.x, 5.0.x and 6.0.x runtimes (and removed the olders), but both didn't updated the ".NET Core Runtime & Hosting Bundles" for 3.1.x and 5.0.x (just the 6.0.x).

    So at the end i have this:
    Server1 (manually):
    3.1.24 Runtimes / 3.1.24 Hosting Bundle
    5.0.16 Runtimes / 5.0.16 Hosting Bundle
    6.0.4 Runtimes / 6.0.4 Hosting Bundle

    Server2 and Server3 (with WSUS):
    3.1.24 Runtimes / 3.1.23 Hosting Bundle
    5.0.16 Runtimes / 5.0.15 Hosting Bundle
    6.0.4 Runtimes / 6.0.4 Hosting Bundle

  5. RomBrz commented on Apr 28, 2022

    @RomBrz
    Author

    Today i installed on another server, and the same behavior occurs:
    Both 3.1.24 and 5.0.16 installers doesn't updated the Hosting Bundle package.

    Seems like the problem with the 6.0.4 in this case was something with the Windows Update itself (and, as i told early, what i did to solve).

    Funny fact: The manual Hosting Bundle package doesn't recognize the 3.1.24 and 5.0.16 Windows Update installation: both installers open as i didn't have anything related installed (welcome to the installation, next next finish).
    The 6.0.4 installer recognize the Windows Update installation (shows me the "modify, repair or uninstall" page)

  6. wtgodbe commented on Apr 28, 2022

    @wtgodbe
    Member

    Could be related to the VS/SDK mismatch from 6.0.4 (we inadvertently shipped mismatched runtimes in Visual Studio vs. the Dotnet SDK in 6.0.4) - do these machines have VS installed? You could try the steps described here: https://developercommunity.visualstudio.com/t/PackageId:MicrosoftAspNetCoreSharedFra/10015847#T-N10018891

  7. RomBrz commented on Apr 28, 2022

    @RomBrz
    Author

    These servers are for publishing applications, so they don't have VS installed, and i never installed the SDK on it.

    Before i knew that i could update DotNet using WSUS/WU, i just downloaded each month the Hosting Bundle and install it on my IIS Servers so the DEV team could publish DotNet Core apps with existing DotNet Framework apps.

  8. self-assigned this
    on Apr 28, 2022
  9. RomBrz commented on May 12, 2022

    @RomBrz
    Author

    Trying again this month and trying to documentate the things:
    Server before updates:
    image
    The updates available by Windows Update:
    image
    Server after updates:
    image

    Seems like the Hosting Bundle for 3.1.x and 5.0.x are not updating with the Windows Update; only with manual installing of Hosting Bundle.

    Expected behavior (i downloaded both Hosting Bundle from MS site and installed manually):
    image

  10. wtgodbe commented on May 12, 2022

    @wtgodbe
    Member

    Ah, that might be a hint - we recently did work to provide the Hosting Bundle through Microsoft Update - @jamshedd @joeloff @csnellgrove1-zz does MU offer the hosting bundle for 6.0 only, or for 3.1 & 5.0 as well? The change that makes it possible to offer the hosting bundle is present all the way back to 3.1, but I'm not sure whether or not MU actually offers it that far back.

  11. jamshedd commented on May 13, 2022

    @jamshedd
    Member

    Its offered for all versions (not just 6.0).

  12. RomBrz commented on Jun 6, 2022

    @RomBrz
    Author

    Any news with this problem? Right now i have to reinstall the 3 hosting bundle for different reasons:

    • 3.1 and 5.0 not update the Hosting Bundle package
    • 6.0 depending of the server and the applications (or the order of the instalation of the patches) crash during the install, so i have to uninstall everything mannualy, reboot the server, install the previous version, reboot the server again, check for updates and waiting for the windows update update to the latest version.

    The 3.1 and 5.0 question happen on 100% of the servers
    the 6.0 broken installation occurs on "randon" situations, some servers update okay, some servers broke the installation (and the only way to "unbroke" is to do what i told above.

  13. wtgodbe commented on Jun 6, 2022

    @wtgodbe
    Member

    The 3.1/5.0 problem sounds like an issue w/ Windows Update - @jamshedd @csnellgrove1-zz who can we talk to to confirm if/why the hosting bundle isn't being offered for 3.1/5.0? Sounds like @RomBrz has consistently not been offered it for the past 3 releases.

    As for 6.0, are you able to attach logs from the failed install? They should be in your %Temp% folder after the install.

  14. joeloff commented on Jun 6, 2022

    @joeloff
    Member

    The hosting bundle's offering depends on detecting the relevant ANCM copy. If the the 3.1 and 5.0 installs did not include ANCM, it won't be offered - this is one of the reasons why I suggested we should actually do the full bundle detection, rather than looking at the MSIs.

  15. 8 remaining items

  16. RomBrz commented on Aug 25, 2022

    @RomBrz
    Author

    I have a server with just "Hosting Bundle" installed (not the runtimes), this month patch updates the actual Hosting Bundle for both DotNet (3.1.x and 6.0.x) but install the runtimes.
    In my opinion, the update should only update what is already installed, not install the full pack and update everything else..

  17. wtgodbe commented on Aug 25, 2022

    @wtgodbe
    Member

    Do you have the update logs? The hosting bundle is designed to only update what is already installed, if it updated everything that sounds like a bug.

  18. RomBrz commented on Aug 26, 2022

    @RomBrz
    Author

    I'm sending 3 logs:

    1. WindowsUpdate-DotNet6Failed.txt = Server Failed to install DotNet 6.0.x while IIS is running.
      WindowsUpdate-DotNet6Failed.txt

    2. WindowsUpdate-DotNet3Runtime.txt = Server has only Hosting Bundle for 3.1.x, after the update, has Runtime too.
      WindowsUpdate-DotNet3Runtime.txt

    3. WindowsUpdate-DotNet6Runtime.txt = Same as 2, but with DotNet 6.0.x.
      WindowsUpdate-DotNet6Runtime.txt

  19. wtgodbe commented on Aug 26, 2022

    @wtgodbe
    Member

    @RomBrz we would need the MSI logs to determine what went wrong - they'd be in your %temp% folder (of the user that ran the installation), search for %temp%\dd*hosting.log, they should look similar to dd_dd_DotNetCoreWinSvrHosting__20220819002058.log

  20. RomBrz commented on Aug 26, 2022

    @RomBrz
    Author
    1. The log from the server with IIS running that crashed trying to install DotNet 6.
      dd_dd_DotNetCoreWinSvrHosting__20220818090804.log

    2. The server that have only the Hosting Bundle installed. It doesn't have the "dd_dd_*" files, only 4 types of files (3.1.x both x86/x64 and 6.0.x both x86/x64), so i'm sending just one of then the 6.0.x x64.
      Microsoft_.NET_Runtime_-6.0.8(x64)_20220825121103.log

  21. wtgodbe commented on Aug 26, 2022

    @wtgodbe
    Member

    For the first, you're hitting Error 0x80070643, which is often caused by a corrupted .Net Framework on the machine - you could try repairing .Net Framework before re-running the install.

    For the second, is there a log with DotNetCoreWinSvrHosting in the name on the machine? That'd have what we need to figure out the problem

  22. RomBrz commented on Aug 26, 2022

    @RomBrz
    Author

    For the first, you're hitting Error 0x80070643, which is often caused by a corrupted .Net Framework on the machine - you could try repairing .Net Framework before re-running the install.

    As i told before, i can reproduce this error if i click on "Install Windows Updates" while IIS is running; the DotNet 3.1 installs OK while IIS running, DotNet 6 gives this crash and corrupt the installation. In this case: Tried to install, gives this bug; i have to manually uninstall everything related to 6.0.8 AND 6.0.7 (some packages keeps both versions), on this server, change IIS startup to manual/disabled, reboot the server, reinstall the 6.0.7 with the Hosting Bundle Package, THAN install manually the 6.0.8 to work.
    I can reproduce this, have two more servers to update with the same config: If i keep IIS running, will crash. If i disable IIS before setup, installs OK.

    For the second, is there a log with DotNetCoreWinSvrHosting in the name on the machine? That'd have what we need to figure out the problem

    Doesn't have this. All files from the aug 25 (yesterday):
    Logs Available

  23. RomBrz commented on Sep 5, 2022

    @RomBrz
    Author

    Any update?

  24. added this to the 7.0-rc2 milestone on Sep 6, 2022
  25. wtgodbe commented on Sep 6, 2022

    @wtgodbe
    Member

    Sorry for the delays, I've been busy as we're finishing up work for 7.0. I'll work on getting a repro of the 6.0 failure in the near future.

  26. RomBrz commented on Sep 20, 2022

    @RomBrz
    Author

    Installing 6.0.9 and 3.1.29.
    Tried this month without rebooting and/or stopping IIS before install the patches.
    3.1.29 installed OK.
    6.0.9 give an error, i clicked on retry and seems to install. But after reboot, seems like the Hosting Bundle 6.0.8 wasn't uninstalled:
    DotNetCore

    Looking at this, seems like that the WU installation of the DotNet 6.x crashes if there's any app running at DotNet 6.x on IIS, and seems like it's related to the Hosting Bundle package itself (as the Runtimes and Shared Framework are both updated).

    This not happens if i change IIS startup to manual and reboot the server before start the WU installation.

  27. RomBrz commented on Oct 26, 2022

    @RomBrz
    Author

    Any update? Right now i'm stopping IIS before WU installation and seems to work.
    But the problem to install everything instead of just update what is already installed continues.
    The server with only Windows Server Hosting + Shared files (not the runtime) after WU installation get to update both Server Hosting + Shared Files AND the latest runtime.
    I have to run the dotnet-uninstall to remove all the runtimes (in the case, 3.1 runtime x64 and x86 + 6.0 runtime x64 and x86).

    For me the behavior should be just update what is installed

  28. RomBrz commented on Apr 27, 2023

    @RomBrz
    Author

    Updating the thread, seems like that with updating DotNet 6 and 7 the problem doesn't happen. One time happened (last month) but the Windows Update itselt tried again and updated okay.
    As 3.1 and 5.0 is on EOL status, the updates aren't a problem anymore.

    The only problem i have right now it's that the WU Installer didn't get what i have installed, so in my case (i install the full hosting bundle when new DotNet is release than uninstall the runtimes, keeping only the Hosting Bundle package), the servers that doesn't have the Runtimes keep installing the Runtimes after WU updates.

    But seems like a different bug, so if this persist i will open another issue.

    Thanks

  29. ghost locked as resolved and limited conversation to collaborators on May 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

area-infrastructurefeature-installers

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions