Thanks Fajar, 

I'm more interested in if I'm right or wrong and why that's the case. 

Incremental snapshot support is in LXD 3.0 but I'm asking in relation to LXC, 
not LXD. And I'm really looking to clear up my (mis)understanding. 


Thanks! 
Lai 


From: "Fajar A. Nugraha" <l...@fajar.net> 
To: "lxc-users" <lxc-users@lists.linuxcontainers.org> 
Sent: Wednesday, March 7, 2018 1:17:07 PM 
Subject: Re: [lxc-users] LXC copy snapshots only to remote? 

On Thu, Mar 8, 2018 at 12:03 AM, Lai Wei-Hwa < [ mailto:wh...@robco.com | 
wh...@robco.com ] > wrote: 



Hi Everyone, 

I'm probably not fully grasping how LXC containers/snapshotting works, but why 
isn't the following possible? 

Host    Container 
        Monday 
        Tuesday 
        Wed 
        Thurs 

H1 
        C1 (fresh Ubuntu) 
        SA (added apache) 
        SB (removed apache and added nginx) 
        SC (hardened nginx config) 
        Host dies 

H2 
        C2 (created from C1 Snapshot B) 
        
        
        SC (with hardened nginx config) 
        

On Tuesday, I snapshot C1 (creating SB) and stop the container. I then jump on 
a new host (H2) and copy snapshot B: 

BQ_BEGIN

H2$ lxc copy H1:C1/SB C2 



At this point, my C2 is equivalent to C1 + SA + SB. Thus, I believe that C1 + 
SA + SB = C2 

On Wednesday, I take Snapshot C on H1. 

I believe that on Wednesday, after taking SC, I should be able to copy SC alone 
to H2. And then on Thursday, when H1 dies, I should be able to go to H2 and 
launch SC (C2 + SC) and have the same container I had on H! when I first took 
Snapshot C. 

If I'm wrong, why am I wrong? If I'm right, how do I copy SC by itself (and not 
the whole container) to H2 on Wednesday? 



BQ_END


I'm pretty sure lxc doesn't do incremental snapshots. 

To get what you want, you need to manage the storage snapshots (and incremental 
send) yourself. For example, if using zfs, you can use sanoid + syncoid. 

-- 
Fajar 

_______________________________________________ 
lxc-users mailing list 
lxc-users@lists.linuxcontainers.org 
http://lists.linuxcontainers.org/listinfo/lxc-users 
_______________________________________________
lxc-users mailing list
lxc-users@lists.linuxcontainers.org
http://lists.linuxcontainers.org/listinfo/lxc-users

Reply via email to