Visual Studio 2022 Community Installer "Sorry, something went wrong"

matt steging 1 Reputation point
2022-05-03T19:29:10.39+00:00

While running the VS Installer I am getting and error of "Sorry, something went wrong The install operation failed."

I have tried researched and tried various proposed solutions such as running the InstallCleanup.exe and deleting the Installer folder and rerunning the VisualStudioSetup but continue to get the same error.

I have tried this on 2017, 2019, and 2022 and get the same error.

I previously had 2017 installed but uninstalled and am not able to reinstall now.

Developer technologies | Visual Studio | Setup
Developer technologies | Visual Studio | Other
{count} votes

5 answers

Sort by: Most helpful
  1. Thomas Weingartner 11 Reputation points
    2022-10-15T11:33:05.547+00:00

    I used the collect.exe tool explained above and saw in dd_BackgroundDownload_nnnn.log the following line:

    [1464:001f][2022-10-15T12:58:18] Warning: Failed to download 'https://download.visualstudio.microsoft.com/download/pr/6e945cf1-e379-4764-89db-b83926f4d271/05d5264b0d6455159b97ce2258ef64312368a86dd38a200ed1b727dedcb59d61/vs_Setup.exe' to

    So I downloaded and executed the vs_Setup.exe manually.

    Afterwards I restarted the VS Installer and I was able to upgrade installed Visual Studio products.

    2 people found this answer helpful.

  2. Stokely 21 Reputation points
    2022-12-01T23:00:25.197+00:00

    After much struggle with Visual Studio 2022 freezing, cycling, stalling, and reporting multiple errors in event logs, I found out it was Windows 10 security that was causing all the issues. Visual Studio often runs apps and builds that manipulate files in multiple folders and uses process that now trigger Microsoft's more complex ransomeware and behavioral security blocks. The problem is neither the IDE or security is communicating any of this anywhere. So your best strategy is to either turn some items off or add folders and apps Visual Studio and .NET use to the security software. Then VS runs perfectly!

    More specifically, try:

    1. In Windows 10-11, go to the "Windows Security" > Virus & Threat Protection > "Ransomware protection"
    2. Either add Visual Studio folders and apps to the "allow an app through Controlled folder access" list (C:\Program Files\Microsoft Visual Studio, etc.) or turn off this feature. The problem is MSBuild and test build run various processes that save files, update folders, and change settings in folders and files across the OS. This also includes IIsExpress, inetpub, and the c:\users{MyUser}\appdata folders. Its a mess!
    3. As proof this is a problem, go look at the folders and applications various application add to the ransomware file and folder list under "allow an app through Controlled folder access". This is evidence this feature is causing major issues and forcing apps to try and work around it. But Visual Studio 2022 appears to be struggling when ransomware blocking is enabled.
    4. Load your Visual Studio application or codebase again and see if you see radical performance gains!

    Extra Performance Settings. Try turning off these processes in Visual Studio as well, and go to manual:

    1. In Visual Studio 2022, turn off all Code Analysis. You have to do this manually for each project by clicking your project, right-click and choose "Properties", then under Code Analysis turn off these live and build features which are also trigger as you code, when saving, or rebuilds are triggered under the new "Hot Reload" feature. You can still manually run code analysis at the top navigation under "Analyze"
    2. Consider turning off all Extensions not needed
    3. Consider turning off all ghost downloads by Nuget and Extensions in the Tools > Options > Extensions and Tools > Options > Nuget Package Manager
    1 person found this answer helpful.
    0 comments No comments

  3. Tianyu Sun-MSFT 34,446 Reputation points Microsoft External Staff
    2022-05-17T06:36:08.693+00:00

    Hi @matt steging ,

    I double checked the log files that you shared above, I can see that the Installer was installed completely but in two dd_setup files, I didn’t find more records about why/when the installer failed/stopped to install VS. It’s like the log didn’t finish recording, but as you know, even the Installer was forced to stop by accident, it will return error codes, or record any simple message like something went wrong and failed to install VS. If you find any other error message recorded, even in other log files, please feel free to let me know.

    Besides, I list some troubleshooting suggestions for you to check:

    1. Please try to disable Endpoint Security(anti-virus software) and then reboot your machine and reinstall VS.
    2. If there is currently no VS installed on your machine, I suggest you try to check whether following folders/registry are removed. If any of them are not cleared, please remember to back up them/it and then remove them/it.
      a. C:\Program Files (x86)\Microsoft Visual Studio
      b. %programdata%\Microsoft\visualstudio\packages
      c. HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\VisualStudio\Setup
      d. HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\Setup
      e. HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Microsoft\VisualStudio\Setup
    3. I doubt some files(maybe system files) were corrupted after you uninstalled VS. You may also try this tool: SFC.exe. Also try to use this tool: troubleshooter.
    4. Please also make sure that the Windows OS is up-to-date, and every pending installed components/packages have been installed.

    Please let me know if any of above suggestions works for you.

    Best Regards,
    Tianyu

    • If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
      Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.
    0 comments No comments

  4. Justin Michel 1 Reputation point
    2022-10-16T11:45:43.417+00:00

    I had a similar problem, but mine actually completed the download, and just failed to run it for unknown reasons.
    See https://stackoverflow.com/questions/71489113/visual-studio-error-sorry-something-went-wrong-the-install-operation-failed

    0 comments No comments

  5. Mehrdad A 1 Reputation point
    2022-12-08T03:04:57.34+00:00

    I just resolved this issue with a very simple step, I installed VS 2022 and then I wanted to install SSIS extension that I got he error that it failed , the I tried the vs Installer and noticed this error (something went wrong ).

    1- I navigated to dir C:\Program Files (x86)\Microsoft Visual Studio
    2- I noticed I have 2 directory for Installer one was hidden and one was not but the newer version name was like Installer.5456544828**( with a lot of digit in the dir name )
    3- I basically renamed the older version dir to Installer_old and renamed the new directory to Installer.
    after this the installer was working fine and was also able to install the SSIS extension on VS 2022
    I hope it helps

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.