Unable to use SQL 2019 after Windows 11 upgrade.

Rob Ainscough 76 Reputation points
2022-06-11T13:56:35.317+00:00

As I posted on StackOver flow here ... I'm unable use SQL 2019 Dev Edition after upgrading to Windows 11. I've tried uninstalling and installing but keep getting SQL Server Setup failed to restore the instance id. As you can see from my stackoverflow link, the SQL 2019 Dev Edition install reports a Error description: Invalid command line argument. Consult the Windows Installer SDK for detailed command line help.

I've tried manually removing per this article here. But still get the same error.

I've run sfc /scannow ... no errors reported
I've run DISM (DISM /online /cleanup-image /scanhealth, DISM /online /cleanup-image /checkhealth, DISM /online /cleanup-image /restorehealth

If I run SQL 2019 Dev Edition installer on my other Windows 10 PC, I have no issues at all.

So there seems to be some problem with the SQL 2019 Dev Edition installer on Windows 11 PC when there was a prior version of SQL installed on Windows 10 that was upgraded to Windows 11.

SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
12,814 questions
0 comments No comments
{count} votes

Accepted answer
  1. Yitzhak Khabinsky 25,116 Reputation points
    2022-06-12T15:06:21.567+00:00

    Hi @Rob Ainscough ,

    The issue is related to system disk sector size greater than 4 KB:
    This article provides solutions for troubleshooting errors during installation or starting SQL Server on Windows 11:

    https://learn.microsoft.com/en-us/troubleshoot/sql/admin/troubleshoot-os-4kb-disk-sector-size#resolutions


3 additional answers

Sort by: Most helpful
  1. Erland Sommarskog 101.9K Reputation points MVP
    2022-06-11T21:16:24.533+00:00

    It might have been a mistake to uninstall. There is a known issue with Windows 11 and some SSDs and for which there is a simple workaround when you already have SQL Server installed.

    Also, I like to point out that it is a foregone conclusion that this issue is related to the Win 11 upgrade. You machine may already have had a disorder, so if you had performed this uninstall + install while you still were on Windows 10, you would have faced the same issue.

    I have seen people running into this error before, but I don't think I have ever understood what is going on. But the file to look at is Details.txt in the install folder. It is very verbose and far from always easy to make sense from.

    0 comments No comments

  2. Rob Ainscough 76 Reputation points
    2022-06-12T19:17:39.827+00:00

    OMG, 2 days later ... big thank you!!

    This:

    REG ADD "HKLM\SYSTEM\CurrentControlSet\Services\stornvme\Parameters\Device" /v "ForcedPhysicalSectorSizeInBytes" /t REG_MULTI_SZ /d "* 4095" /f

    resolved the issue for my Windows 11 PC ... I'm eternally grateful, but at the same time I'm unbelievably pissed off at Microsoft for their incompetence ... 2 days of my life wasted on this.

    Cheers, Rob.

    0 comments No comments

  3. SAinCA_TG 1 Reputation point
    2022-09-29T16:34:24.037+00:00

    Glad I bumped into this one. I was about to uninstall... After finding the msc I had no SQL Services!

    Added the key and verified, then downloaded the Dev-edition iso, mounted, ran Repair, hit Escape for dozens of non-mapped login to securityID dialogs, and all "Successful".

    Gratitude to all the above respondents for the info, refs, solutions, reassurance, and successful recovery from what ought not to have been an issue had MS done things right.

    0 comments No comments