On Thu, Nov 8, 2018 at 2:27 AM, Barbet Alain <alian123sol...@gmail.com> wrote: > Hi ! > Just to give you end of the story: > I move my /var/lib/docker to my home (other partition), and my space > come back ...
I'm not sure why that would matter. Both btrfs du and regular du showed only ~350M used in /var which is about what I'd expect. And also the 'btrfs sub list' output doesn't show any subvolumes/snapshots for Docker. The upstream Docker behavior on Btrfs is that it uses subvolumes and snapshots for everything, quickly you'll see a lot of them. However many distributions override the default Docker behavior, e.g. with Docker storage setup, and will cause it to always favor a particular driver. For example the Docker overlay2 driver, which leverages kernel overlayfs, which will work on any file system including Btrfs. And I'm not exactly sure where the upper dirs are stored, but I'd be surprised if they're not in /var. Anyway, if you're using Docker, moving stuff around will almost certainly break it. And as I'm an extreme expert in messing up Docker storage, I can vouch for the strategy of stopping the docker daemon, recursively deleting everything in /var/lib/docker/ and then starting Docker. Now you get to go fetch all your images again. And anyway, you shouldn't be storing any data in the containers, they should be throwaway things, important data should be stored elsewhere including any state information for the container. :-D Avoid container misery by having a workflow that expects containers to be transient disposable objects. -- Chris Murphy