-
Notifications
You must be signed in to change notification settings - Fork 67
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot install Visual Studio inside a server core image #540
Comments
Thank you for creating an Issue. Please note that GitHub is not an official channel for Microsoft support requests. To create an official support request, please open a ticket here. Microsoft and the GitHub Community strive to provide a best effort in answering questions and supporting Issues on GitHub. |
@zillemarco Hey, thanks for bringing up this Issue. Have you tried to use a recent Windows Server Core LTSC 2022 image? Or only the 2019 version? I ask because we don't provide support for 2019 anymore. |
Hi @ntrappe-msft, I did not because I don't have any server running win2022 and docker, and it wouldn't be a solution anyway because the server the image I'm trying to build is running win2019 unfortunately. I also tried installing other software in the image, just to make sure it wasn't only related to Visual Studio, but anything I try to install it fail. Moreover, the last image for ltsc2019 was built and published less than a month ago, so isn't it still kinda supported? |
On a Windows LTSC 2022 Image, i receive this error: Does anyone know how might resolve it? |
Hey there! Thanks for sharing the error details. The “not enough space on the disk” message often means that Docker’s storage location (typically on the C: drive by default) is running low on available space. A few things you can try: 1. Check Available Disk Space:Open File Explorer, go to “This PC” → “Local Disk (C:)” and verify the remaining free space. If it’s low or in the red, you’ll need to free up some space. 2. Increase VM Disk Size (If Applicable):If you’re running inside a VM, open Hyper-V Manager, expand the size of the attached .vhdx file, then inside the guest OS, use Disk Management to extend the C drive partition. This can give Docker more breathing room. 3. Clean Up Docker Resources:Run docker volume ls to see if you have old volumes that can be removed. Unused volumes can eat up a lot of space. 4. Adjust Docker Storage Settings:Since you mentioned you already tried setting the Hopefully that helps. |
@zillemarco When you try to build the image from the Dockerfile, is it failing on a specific line? Or it is dropping that error upon completion? |
Hi @ntrappe-msft, it's not failing on any specific line of the Dockerfile unfortunately. It just quits after the I was able to try the same Dockerfile but on a Windows Server 2022 (obviously the docker base image was changed as well) and that worked, so it seems only relater to running the installed on the To be clear: I tested on WinServer 2022 just for the sake of making sure it worked there, we still can't deprecate WinServer 2019 unfortunately. Update: I just noticed that a new image for The image IDs I tested are:
|
@zillemarco hey, I am having the same issue base on a |
@ericoporto unfortunately no. We are still stuck at not being able to update some of our docker images due to this bug. @ntrappe-msft do you have any updates on this? Looking back at your suggestions (#540 (comment)), I checked the available space on our server running docker build, and we are in fact running out of space on the OS disk (on the |
For "fun" I tested another Dockerfile we used to generate a Docker image with VS2017 and, ... still the same error. The |
For me, the only solution is to clean the whole Docker System every time with
when building an image with Visual Studio |
@madduci thanks for the suggestion but it unfortunately did not work for me. BTW, I also tried upgrading our docker and we are now running |
Hi @zillemarco, I wonder if the following approach may help you, Try the following command in an admin level powershell prompt, this explicitly calls the curl command from the Dockerfile to install VS buildtools:
|
Hi @sabinamiezah-msft, just to clarify, how would you like me to run that command? Do you mean from inside a container running the And what's the output you'd be expecting? From inside the container I can't run the installer like that because there's no UI. |
Describe the bug
I am trying to install VS 2022 build tools inside of a docker container to build an image and use it for our CI builds.
I already had an image working, but now I needed to update a dependency so I had to rebuild it (TL; DR: it worked last time I built it).
However, the installation now fails with error code 1603.
I have extracted the VS installation logs from the container and the main issue seems to be this:
I run an
sfc /scannow
inside brand new container using the image and it did find some corrupted files, so maybe the image itself has issues?To Reproduce
You should be able to reproduce this by building the following Dockerfile (based on the example here, where you can also find the Install.cmd file contents):
Expected behavior
The image builds without issues.
Configuration:
mcr.microsoft.com/windows/servercore:ltsc2019
The text was updated successfully, but these errors were encountered: