Reputation: 4948
I am running docker on my
windows 10 home
machine. So it is the older version of docker not the hyper v version.
I have setup a sql server docker container however when I run it it exits with the error
Exited (1)
When I look at the logs it says
sqlservr: This program requires a machine with at least 2000 megabytes of memory. /opt/mssql/bin/sqlservr: This program requires a machine with at least 2000 megabytes of memory.
However I have 8Gb of memory on my machine and I have at least 3.5 Gb free when running docker. I have tried using the --memory flag to allocate over 2Gb for the container (as the docs state that it needs 2Gb for the sql server image) but it still exits...
Does anyone know what is potentially the issue?
Upvotes: 1
Views: 2185
Reputation: 11
create .wslconfig file in your user folder
[wsl2]
memory=4GB # Limits VM memory in WSL 2 up to GB
processors=2 # Makes the WSL 2 VM use two virtual processors
Upvotes: 1
Reputation: 101
I had the same issue and I got it solved by using this docker image https://hub.docker.com/r/justin2004/mssql_server_tiny
this is my docker-compose file:
services:
db:
image: justin2004/mssql_server_tiny
environment:
- ACCEPT_EULA=Y
- SA_PASSWORD=@P1ssword@
ports:
- '1433:1433'
expose:
- 1433
Upvotes: 1