Why is my Docker.raw file so huge and how can I fix it?

0
7
Asked By CuriousPenguin92 On

I'm seeing a massive Docker.raw file taking up around 171.96 GiB in my system: /home/my_user/.docker/desktop/vms/0/data/Docker.raw. I've tried running all the purge commands I can think of, but the size keeps growing. I'm not sure what's causing this or how to resolve it, and it's getting really frustrating. Can anyone help me out here?

4 Answers

Answered By TechieTurtle On

Another thing you might want to consider is switching to the native Docker CLI instead of Docker Desktop. Using Docker on Linux natively avoids the VM overhead that Docker Desktop creates. Also, check your Docker settings; your volume bindings could be creating large files without you noticing, contributing to the size of that Docker.raw.

Answered By WittyWoodpecker45 On

You could just delete that Docker.raw file and then restart your machine. The file is part of a VM that Docker runs, and it doesn’t shrink back down automatically when you delete files inside Docker. Deleting it and restarting will create a new one, which will also increase again over time as you use Docker.

Answered By QuickFixOtter On

You can also set a max size limit for Docker images and containers to help control how big they can get.

Answered By EcoFriendlySquirrel On

What OS are you using? It looks like you’re on Linux since /home/my_user doesn't seem like a Mac or Windows path. If you're on Ubuntu, I'd recommend not using Docker Desktop at all; it's often unnecessary for Linux users.

Related Questions

LEAVE A REPLY

Please enter your comment!
Please enter your name here

This site uses Akismet to reduce spam. Learn how your comment data is processed.