In the following videos I’m showing how to use dotTrace to take a profiling session and how to take a memory dump to analyze and troubleshoot performance issues of your application running in Docker containers.
In my previous post you can find a quick way to get your Sitecore Demo up and running, have a look!
Profile Sitecore running in Docker containers
Getting a memory dump from a container
I hope this helps you on your performance troubleshooting when running Docker containers!
Open PowerShell with admin rights and navigate to your repository clone folder: cd C:\Projects\Sitecore.Demo.Platform
Create certificates and initialize the environment file: .\init.ps1 -InitEnv -LicenseXmlPath C:\license\license.xml -AdminPassword b. (You can change the admin password and the license.xml file path to match your needs).
Pull the latest demo Docker images: docker-compose pull
Stop the IIS service: iisreset /stop
Start the demo containers: docker-compose up -d
Check the progress of the initialization by viewing the init container’s logs: docker-compose logs -f init
If you get the following error
“ERROR: for traefik Cannot start service traefik: failed to create endpoint sitecore-xp0_traefik_1 on network nat: failed during hnsCallRawResponse: hnsCall failed in Win32: The process cannot access the file because it is being used by another process. (0x20)”
This normally means a port that is needed is already in use by another service. Make sure any of those ports are in use: 443, 8079, 8081, 8984, and 14330. Have a look here for more details.
In my case I had the port 8079 in use by Java:
Just by stopping the service fixed the issue. (Also make sure you stopped IIS as I mentioned in the first step).
If the issue still, and any of the needed ports are in use, you can also try this: