Forum Discussion

M_Rusu's avatar
M_Rusu
Tin Contributor
Aug 17, 2023
Solved

SQL Server 2019 CU22 (KB5027702) does not install correctly - crashes the server

Attempted to install SQL Server 2019 CU22 (KB5027702).

Installation did not complete and I was unable to restart the database engine any more. Got the following error message: "SQL Server is in script upgrade mode"

I had to uninstall this update, please investigate.

14 Replies

  • For sure the SQL error log has a clue on what part of the upgrade fail. to see it you have to open the ERRORLOG file using Windows Explorer
    Another way to troubleshoot it is bay starting the SQL Service using Trace Flag 902 which will skip the execution of the upgrade so service will start but the databases won't be upgraded ( and you will be able to solve the root problem on why the installation failed)

    https://techcommunity.microsoft.com/t5/sql-server-support-blog/use-trace-flag-902-tf902-to-bring-up-your-sql-service-in-failed/ba-p/2963393

    https://www.sqlservercentral.com/blogs/use-trace-flag-902-to-recover-from-a-cumulative-update-failure
    • M_Rusu's avatar
      M_Rusu
      Tin Contributor

      Javier_Villegas 

      Tried the same action as VK-DBA: reinstalled the patch, no result, server still in crash mode.

      The only solution was to completely uninstall it from Windows Update history.

      I can look through the logs of course, but it never happened before, all past SQL Server 2019 patches installed correctly. There was no relevant message about the error as well, just "SQL Server Agent cannot be started"

      • Could you share the error log ? for sure there is something that gives a clue about what is going on
    • VK_DBA's avatar
      VK_DBA
      Copper Contributor

      Javier_Villegas thank you for your reply. I have done exactly what is described in the article, started SQL in bypass update mode with flag T902, but havent figured out was went wrong during patch installation. I reinstalled SQL and tried again and ran into the same problem. I have opened ticket with Microsoft and waiting for resolution.

  • VK_DBA's avatar
    VK_DBA
    Copper Contributor

    M_Rusu I experienced exactly the same issue and had to rebuild SQL

    • M_Rusu's avatar
      M_Rusu
      Tin Contributor

      VK_DBA 

      Thank you for confirming there is an issue with the latest patch. I cannot see any update from Microsoft yet....