I have installed Docker in my Windows 11 home edition and tried to pull Oracle standard DB image from container-registry.oracle.com. However i got the following error.
Error response from daemon: Get “https://container-registry.oracle.com/v2/”: dialing container-registry.oracle.com:443 no HTTPS proxy: resolving host container-registry.oracle.com: lookup container-registry.oracle.com: no such host.
Any idea on how to resolve this error.
PS : I’m using ubuntu 18.04 as WSL2. System has 8 gb ram, 512 gb SSD and has AMD ryzen 5 series as chip.
Have anyone any suggestions how to solve, or at least how to debug this problem?
Add below mention entry to your windows host file.
run following commands to restart daemon and docker service in WSL2 Linux
sudo systemctl daemon-reload
sudo systemctl restart docker
After a while it got connected but again it got connected while pulling the image from Oracle registery stating the same reason
- Make sure you shut down Docker and any other instances of wsl2. You can do this by going to a command prompt and type the command
wsl — shutdown.
- To create a .wslconfig file, simply open your File Explorer, and type and enter %UserProfile% to go to your profile directory in Windows.
- Docker or WSL2 by default does not create these config files so we should do it ourselves. Create a new file called .wslconfig (make sure there are no .txt at the end)
Settings apply across all Linux distros running on WSL 2
Limits VM memory to use no more than 4 GB, this can be set as whole numbers using GB or MB
Sets the VM to use two virtual processors
Sets additional kernel parameters, in this case enabling older Linux base images such as Centos 6
kernelCommandLine = vsyscall=emulate
Sets amount of swap storage space to 8GB, default is 25% of available RAM
Sets swapfile path location, default is %USERPROFILE%\AppData\Local\Temp\swap.vhdx
Disable page reporting so WSL retains all allocated memory claimed from Windows and releases none back when free
Turn off default connection to bind WSL 2 localhost to Windows localhost
Disables nested virtualization
Turns on output console showing contents of dmesg when opening a WSL 2 distro for debugging
start WLS2 and docker and check.