Reputation: 1280
I have a performance problems deploying SQL Server on Docker. I write as docker-compose like this :
version: '3'
services:
mssql:
restart: always
container_name: mssql
image: mcr.microsoft.com/mssql/server:2017-latest
user: root
environment:
- SA_PASSWORD=PASSWORD-SA
- ACCEPT_EULA=Y
- MSSQL_PID=Developer
volumes:
- /store/backup:/var/opt/mssql/backup:rw
- /store/data:/var/opt/mssql/data:rw
- /store/log:/var/opt/mssql/log:rw
- /store/secrets:/var/opt/mssql/secrets:rw
logging:
driver: "json-file"
options:
max-file: "1"
max-size: "1m"
deploy:
resources:
limits:
cpus: 0.75
memory: 80G
Everything work well, but in running production query very slow. Compare to select a table with same data row - result very difference:
Any suggestion about tuning SQL Server on Docker?
Thanks
Upvotes: 3
Views: 5104
Reputation: 1280
Thanks for comments from Mr @AlwaysLearning and @AaronBertrand. I change docker-compose on resources
resources:
limits:
cpus: 40
memory: 100G
After that i change max memory on TSQL with :
sp_configure 'show advanced options', 1;
GO
RECONFIGURE;
GO
sp_configure 'max server memory', 100000;
GO
RECONFIGURE;
GO
And everthing fast right now.
Upvotes: 3