[lxc-users] Diff between two directory (rootFS) of two containers

Fajar A. Nugraha list at fajar.net
Sun Sep 3 15:55:58 UTC 2017


On Sat, Sep 2, 2017 at 4:56 PM, Thouraya TH <thouraya87 at gmail.com> wrote:
> Hi all,
>
> Please, i have created two containers (Ubuntu).
> Is the two rootFS directory are similar ? Is it the same content ?

Probably. Giving more details (as in, why are you asking this? are you
doing a school assignment? are you implementing lxc on a new system
that will be used for shared hosting and want to find most efficient
use of space?) would help you get the answers you want.

When using lxc1 (old lxc-*) commands, the templates would create a
cache. Containers (using the same template) created close-enough (in
time) to each other would mostly be COPIES of the cache (i.e. mostly
same content, use triple the space: one for the template, one for each
container).

With lxd and the default zfs storage pool, images would be cached as
necessary, and containers (using the same image) created close-enough
(in time) to each other would mostly be CLONES of the image (i.e.
start with same content, sharing the SAME disk space, but then each
container have their own configuration files).

However if you create them several days apart, there will be a chance
that the template/image has been updated, thus making the content (and
the disk space used) different, even when they're using the same
'ubuntu 16.04' template/image.

-- 
Fajar


More information about the lxc-users mailing list