Skip to content
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

Building the mssql-server-windows-developer dockerfile fails #420

Open
ducttapecoder-vt opened this issue Feb 11, 2019 · 6 comments
Open

Comments

@ducttapecoder-vt
Copy link

ducttapecoder-vt commented Feb 11, 2019

Long story short, I'm new to docker and trying to add Full Text Search (FTS) to the windows SQL developer image and it's not working.

Docker 2.0.0.2 30215. Engine 18.09.1
Windows 10 1809

I've tried rebuilding the developer image to add FTS a lot of different times and different ways from different machines (All windows 10) and I'm at a loss. My primary dev machine is disconnected from the internet so I had copied the exe and box files and added in the needed COPY commands. I had issues with setup.exe not being recognized as a command (like this ) and lots of other silly things. The setup.exe usually rejects the /configurationfile=configuration.ini option. Most variations, if I get it to build at all, I end up with an image that fails to run. The container says "created" for all eternity (I just terminated one that said "created 10 days ago" and was still in the "Created" state) and forces me to restart the docker service as 'stop', 'kill', and 'rm' all fail.

I reached one point where I got a 'out of memory exception' and I discovered the distinction between hyper-v (windows 10) and process isolation (server) and the 1GB RAM limit on Hyper-V. I started using -m 4GB which helped some.

One time after that I was able to get the FTS and CU13 installed but I had stripped out the CMD commands. I then tried a FROM on that image with the CMD and got the 'forever created, never started' (FCNS) containers again.

I tried recreating the successful image and adding the CMD and other items I had stripped out but got more FCNS containers.

I also tried setting a FROM the existing developer image and running setup to add FTS but no dice there either.

I finally gave up and put docker on an internet machine and tried the dockerfile verbatim and it still failed. I ran it again and got a different error! I'm pretty sure I'm not insane (I hope) so something must be wrong with docker right?

The most recent time, it failed on step 9/12 with:

CreateComputeSystem 190fb331cadf01bacbf437fbc3a09a4d68055208fe8ab504b00931d8156a0372: hcsshim: timeout waiting for notification

The time before that:

CreateComputeSystem 5cd46655260f2b36904b1915b060319607bac5940281b4c4a8d485b072d5558c: This operation returned because the timeout period expired.

PS C:\Users\<user>\Desktop\SQL-dev> docker build . -m 4GB -t mssql
Sending build context to Docker daemon  11.26kB
Step 1/12 : FROM microsoft/windowsservercore
 ---> ea9f7aa13d03
Step 2/12 : LABEL maintainer "Perry Skountrianos"
 ---> Running in 601879c3377e
Removing intermediate container 601879c3377e
 ---> 0cb3abc42775
Step 3/12 : ENV exe "https://go.microsoft.com/fwlink/?linkid=840945"
 ---> Running in 7d9e3cc61dd9
Removing intermediate container 7d9e3cc61dd9
 ---> 004ec3c16126
Step 4/12 : ENV box "https://go.microsoft.com/fwlink/?linkid=840944"
 ---> Running in 517193e3ac72
Removing intermediate container 517193e3ac72
 ---> 8791da287c6d
Step 5/12 : ENV sa_password="_"     attach_dbs="[]"     ACCEPT_EULA="_"     sa_password_path="C:\ProgramData\Docker\secrets\sa-password"
 ---> Running in a75102447508
Removing intermediate container a75102447508
 ---> 3284fa21806f
Step 6/12 : SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"]
 ---> Running in e678e598e1ac
Removing intermediate container e678e598e1ac
 ---> ad9c76d97dc1
Step 7/12 : COPY start.ps1 /
 ---> 1f5ab693025e
Step 8/12 : WORKDIR /
 ---> Running in 9a735dd39ac2
Removing intermediate container 9a735dd39ac2
 ---> b8001c68d4b5
Step 9/12 : RUN Invoke-WebRequest -Uri $env:box -OutFile SQL.box ;         Invoke-WebRequest -Uri $env:exe -OutFile SQL.exe ;         Start-Process -Wait -FilePath .\SQL.exe -ArgumentList /qs, /x:setup ;         .\setup\setup.exe /q /ACTION=Install /INSTANCENAME=MSSQLSERVER /FEATURES=SQLEngine /UPDATEENABLED=0 /SQLSVCACCOUNT='NT AUTHORITY\System' /SQLSYSADMINACCOUNTS='BUILTIN\ADMINISTRATORS' /TCPENABLED=1 /NPENABLED=0 /IACCEPTSQLSERVERLICENSETERMS ;         Remove-Item -Recurse -Force SQL.exe, SQL.box, setup
 ---> Running in 190fb331cadf
CreateComputeSystem 190fb331cadf01bacbf437fbc3a09a4d68055208fe8ab504b00931d8156a0372: hcsshim: timeout waiting for notification
(extra info: {"SystemType":"Container","Name":"190fb331cadf01bacbf437fbc3a09a4d68055208fe8ab504b00931d8156a0372","Owner":"docker","IgnoreFlushesDuringBoot":true,"LayerFolderPath":"C:\\ProgramData\\Docker\\windowsfilter\\190fb331cadf01bacbf437fbc3a09a4d68055208fe8ab504b00931d8156a0372","Layers":[{"ID":"df180ec2-1108-5226-85d4-f88b5baef890","Path":"C:\\ProgramData\\Docker\\windowsfilter\\425ff525b0260c0e27bf9d008300d611d49a9ff5be94cc35a1c59325e3a8c36d"},{"ID":"26b8735b-a069-5716-818d-c1d14a872c72","Path":"C:\\ProgramData\\Docker\\windowsfilter\\6112d8eab7d9fb89386d487fa497c97320bc93b36a9725564dd92cc3e3e431eb"},{"ID":"88b049b8-00e5-56c1-acc0-39aee0222fba","Path":"C:\\ProgramData\\Docker\\windowsfilter\\f3556ebfa70f01246d2e6ddcc709002c8a5613f104d7196bb2aa12af3c6404c8"},{"ID":"f8b796b2-8554-5669-bf4c-8806488b0e82","Path":"C:\\ProgramData\\Docker\\windowsfilter\\959373b58f84e0bb81adc3a10c5def17211931a28cd152ea557466b842d16321"},{"ID":"82d9e35e-08dc-5539-bfd3-6231ad2b3db5","Path":"C:\\ProgramData\\Docker\\windowsfilter\\2c7349333557954c54547baa19198c549f25ac12b5e6168ee3686b8cbcd9ae26"},{"ID":"e042501d-c657-5114-b555-dfd2a1f66b5f","Path":"C:\\ProgramData\\Docker\\windowsfilter\\915ca32b87e045c85ab1506ccadb13a27c53f0e843b65ae80a1f40c617bffd40"},{"ID":"bdab63f4-b521-5ca1-ad3b-2174223c8866","Path":"C:\\ProgramData\\Docker\\windowsfilter\\e0621d19bc88bac0ed7e6a7cf28cd42b892cbcbcd56f415afbed13a4a1a376a4"},{"ID":"e1fb1b1b-e222-50a7-9cde-025db386f0fc","Path":"C:\\ProgramData\\Docker\\windowsfilter\\a17681a7c340b1f04cf2bc82b4bc4ddd092668eefc9cbcb513cb1b6dc8a6e363"},{"ID":"585ed0c9-f01c-57b1-bf25-82b106e3defe","Path":"C:\\ProgramData\\Docker\\windowsfilter\\874efe95b283614d91d0706c73c56334e87344ab06287236eca308b348de19cb"}],"MemoryMaximumInMB":4096,"HostName":"190fb331cadf","HvPartition":true,"EndpointList":["5D921656-0D23-4E1D-981A-29752E8CEE18"],"HvRuntime":{"ImagePath":"C:\\ProgramData\\Docker\\windowsfilter\\a17681a7c340b1f04cf2bc82b4bc4ddd092668eefc9cbcb513cb1b6dc8a6e363\\UtilityVM"},"AllowUnqualifiedDNSQuery":true})

How do I even begin troubleshooting a generic timeout? Why am I getting so many FCNS containers?

P.S. When docker 18.09.1 released, I tried doing process isolation with servercore:1809 but it said my OS didn't match (duh, but I thought the Windows 10 1809 kernel matched the server 2016 1809 kernel and that was sufficient?). I could try a Windows 10 container but that seems completely pointless. I'm working towards a Server 2016 VM to test this on, but it should work from Windows 10!

@ducttapecoder-vt
Copy link
Author

After more digging, seems my issue is related to hcsshim #152.

@forkazmoden
Copy link

Hi,

Have you tried with the microsoft/mssql-server-windows-developer image. This image is compatible with Windows Server 2016 (Core, with Desktop) and Windows 10 (Professional, Enterprise - Anniversary Edition) OS Hosts. Please refer to microsoft/mssql-server-windows-developer.

@ducttapecoder-vt
Copy link
Author

Hi,

Have you tried with the microsoft/mssql-server-windows-developer image. This image is compatible with Windows Server 2016 (Core, with Desktop) and Windows 10 (Professional, Enterprise - Anniversary Edition) OS Hosts. Please refer to microsoft/mssql-server-windows-developer.

@forkazmoden, not to be rude but it doesn't seem like you read my post at all. From my initial description I'm trying to modify the microsoft/mssql-server-windows-developer image to add Full Text Search. If I could directly use the image, I would save myself the trouble of modifying it, but they have only included the base engine with the install.

@SubjectiveReality
Copy link

SubjectiveReality commented May 14, 2019

@ducttapecoder-vt did you find a solution? I'm running into the same issue trying to build a modified image of microsoft/mssql-server-windows-developer on Windows 10, with docker-desktop.

Update
I was able to build on Windows 10 after updating the FROM in the dockerfile to FROM mcr.microsoft.com/windows/servercore:ltsc2019 because of docker/for-win#3761

@ducttapecoder-vt
Copy link
Author

ducttapecoder-vt commented May 14, 2019 via email

@SubjectiveReality
Copy link

Interesting information, thank you! I edited my comment above as I found my solution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants