How do I update the Visual Studio 2022 installer on an offline computer? Note that it refers to "setup.exe", not the VS main program

正寅 吴 0 Reputation points
2025-03-07T06:00:11.7166667+00:00

I had a problem removing an extension.click Modify Prompt: Failed to download installer update. Make sure you are connected to the network and try again.The installer version is 3.10.2157.28521 , The software version is is Visual Studio Community 2022 17.9.2

Visual Studio Setup
Visual Studio Setup
Visual Studio: A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.Setup: The procedures involved in preparing a software program or application to operate within a computer or mobile device.
1,108 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Tianyu Sun-MSFT 33,391 Reputation points Microsoft External Staff
    2025-03-07T13:18:25.6666667+00:00

    Hi @正寅 吴 ,

    Installing or updating VS/VS Installer offline includes two parts:

    Part one => prepare the layout(on machine with network),  

    Part two => install/update from the layout(on machine offline).

    You need to update the layout to include the newer version of VS Installer(part one), move the layout to offline machine and update the VS Installer(part two).

    Before starting, you need to firstly confirm if the installed VS was installed by using a layout. Here are two situations:

    One => the installed VS was installed by using a layout,

    Two => the installed VS was installed online, but now, the machine was offline.

    We are talking about the first situation. So, you should know the location of this layout, as you need to move it to the machine with network, update it and move it back to this offline machine and update the VS Installer.

    Additional important thing is that, on part one, based on my test, updating the VS Installer separately in layout is not supported. You need to update the whole layout. However, on part two, after you move the updated layout to the offline machine, you can choose to only update VS Installer, not VS.

    So, for part one, you can move the layout to the machine with network. Download the latest VS bootstrapper file from here: Downloads. Run the command like following:

    C:\XXXX\VisualStudioSetup.exe --layout C:\XXXX\MyLayout

    You need to change the paths to your specific paths. The --layout command is enough, see this document: Update the layout to the most current version of the product for more details.

    After the layout has been updated. Move it to offline machine.

    For part two, use the command like following:

    C:\XXXX\MyLayout\vs_xxxxxx.exe --update to update only VS Installer(details: Update).

    Note, please backup your previous layout before you try to update it. As, if you fail to update VS Installer or VS is updated by mistake, you can use this previous layout to roll back VS.

    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

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.