Incrementally updating a copied container

(Andrew Wilson) #1

So I am totally sold on LXC for running my small business services. It’s brilliant. BIG THANK YOU.

One of the things I have successfully experimented with is copying containers from one machine to another. Even a 138GB container (a Nextcloud instance - with a ton of files) was successfully copied from one physical machine to another and (re)started successfully. I am blown away.

This is already forming part of a “disaster recovery” option for me, where I have a machine in active service and one idle, but otherwise very current backup ready and waiting in the winds.

This is great for a LAN where network speeds can support even very big containers, but copying very large containers over the internet is as much fun as doing my taxes. So I have wondered if that can be streamlined…

Consider container c1 on machine1, with a snapshot snap1, which I copy to machine2 using:

lxc copy c1/snap1 machine2:c1-bak

(This is what I do now. Works brilliantly).

Now let’s assume container machine1:c1 is being used and thus gets updated over a period of time, so I make another snapshot c1/snap2. Right now, I have to send another full copy of c1/snap2 to machine2. The storage is not an issue, but the transfer time can be (for WAN especially).

Is it POSSIBLE to (add a feature) to UPDATE container c1-BAK by applying just an UPDATE from container c1.

It would be the equivalent of copying the difference between c1/snap1 and an even more up to date c1/snap2. That would drastically cut down the amount of data that needs to be sent, making incremental backups a reality.

This is easy to ask, so I ask, but I more than appreciate that the complexities might just make this impossible…doing taxes might actually be more fun than trying to solve this!

Thanks again so much for such a brilliant product!


(Stéphane Graber) #2

It’s not right now but we have an open issue and planned work to make this happen.

(Andrew Wilson) #3

Thank you. Nice to know it’s a worthy idea as well. Have a great weekend. V/R

(Stéphane Graber) #4

Yeah, we have a whole bunch of users who’d love that to effectively maintain some kind of LXD backup server.