How to backup lxc and restore in QNAP NAS
Backup:
1 2 |
cd /var/lib/lxc/${lxc_name}/ tar --numeric-owner -czvf ${lxc_name}.tar.gz ./* |
Restore:
1 2 3 |
mkdir/var/lib/lxc/${lxc_name}/ cd/var/lib/lxc/${lxc_name}/ tar --numeric-owner -xzvf ${lxc_name}.tar.gz . |
${lxc_name} should be your lxc`s name.