wiki:lxc_commands
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revision | |||
| wiki:lxc_commands [2022/10/08 09:35] – add rename container antisa | wiki:lxc_commands [2022/10/08 09:38] (current) – add lxc mount host directory and move containers antisa | ||
|---|---|---|---|
| Line 26: | Line 26: | ||
| lxc.rootfs = / | lxc.rootfs = / | ||
| lxc.mount = / | lxc.mount = / | ||
| + | |||
| + | |||
| + | ===== lxc mount host directory inside container ===== | ||
| + | |||
| + | Add to config: | ||
| + | |||
| + | lxc.mount.entry=/ | ||
| + | |||
| + | ===== Moving lxc containers ===== | ||
| + | cd / | ||
| + | tar --numeric-owner -czvf container_fs-$(date +%Y%m%d).tar.gz ./* | ||
| + | |||
| + | From one partition to another: | ||
| + | |||
| + | cp -a / | ||
| ====== Tested on ====== | ====== Tested on ====== | ||
| * | * | ||
| Line 32: | Line 47: | ||
| ====== References ====== | ====== References ====== | ||
| + | * http:// | ||
wiki/lxc_commands.1665221755.txt.gz · Last modified: by antisa
