Skip to main content
tags
Source Link
countermode
  • 7.8k
  • 5
  • 34
  • 59

I am using ZFS on Linux, and have some question regarding snapshots. I have following structure mypool/HOME mounts /home mypool/HOME/root mounts /root mypool/ROOT mounts none mypool/ROOT/rootfs mounts / mypool/ROOT/rootfs/OPT mounts /opt mypool/ROOT/rootfs/USR mounts /usr mypool/ROOT/rootfs/VAR mounts /var mypool/docker mounts /var/lib/docker

mypool/HOME mounts /home
mypool/HOME/root mounts /root
mypool/ROOT mounts none
mypool/ROOT/rootfs mounts /
mypool/ROOT/rootfs/OPT  mounts /opt
mypool/ROOT/rootfs/USR  mounts /usr
mypool/ROOT/rootfs/VAR mounts /var
mypool/docker mounts /var/lib/docker

I want to backup all of this by cron task when I run zfs snapshot -r mypool/HOME@todayzfs snapshot -r mypool/HOME@today, it creates snapshot recursively. But after I copy something heavy to /home/home, and create another snapshot, it shows used 0 or a few kb.

I want to be sure, that it backups mypool/HOMEmypool/HOME and mypool/HOME/rootmypool/HOME/root. is the -r option works for both?

Same with docker. Docker have own snapshots/clones/subvolumes on it's volume. If I do zfs snapshot -r mypool/dockerzfs snapshot -r mypool/docker, will it backup all data as it is on this moment? If some subvolumes appear/disappear, can I restore the same state it was from snapshot?

Thanks

I am using ZFS on Linux, and have some question regarding snapshots. I have following structure mypool/HOME mounts /home mypool/HOME/root mounts /root mypool/ROOT mounts none mypool/ROOT/rootfs mounts / mypool/ROOT/rootfs/OPT mounts /opt mypool/ROOT/rootfs/USR mounts /usr mypool/ROOT/rootfs/VAR mounts /var mypool/docker mounts /var/lib/docker

I want to backup all of this by cron task when I run zfs snapshot -r mypool/HOME@today, it creates snapshot recursively. But after I copy something heavy to /home, and create another snapshot, it shows used 0 or a few kb.

I want to be sure, that it backups mypool/HOME and mypool/HOME/root. is the -r option works for both?

Same with docker. Docker have own snapshots/clones/subvolumes on it's volume. If I do zfs snapshot -r mypool/docker, will it backup all data as it is on this moment? If some subvolumes appear/disappear, can I restore the same state it was from snapshot?

Thanks

I am using ZFS on Linux, and have some question regarding snapshots. I have following structure

mypool/HOME mounts /home
mypool/HOME/root mounts /root
mypool/ROOT mounts none
mypool/ROOT/rootfs mounts /
mypool/ROOT/rootfs/OPT  mounts /opt
mypool/ROOT/rootfs/USR  mounts /usr
mypool/ROOT/rootfs/VAR mounts /var
mypool/docker mounts /var/lib/docker

I want to backup all of this by cron task when I run zfs snapshot -r mypool/HOME@today, it creates snapshot recursively. But after I copy something heavy to /home, and create another snapshot, it shows used 0 or a few kb.

I want to be sure, that it backups mypool/HOME and mypool/HOME/root. is the -r option works for both?

Same with docker. Docker have own snapshots/clones/subvolumes on it's volume. If I do zfs snapshot -r mypool/docker, will it backup all data as it is on this moment? If some subvolumes appear/disappear, can I restore the same state it was from snapshot?

Source Link
Ural
  • 486
  • 1
  • 5
  • 8

ZFS on Linux snapshot recursively volume and subvolumes

I am using ZFS on Linux, and have some question regarding snapshots. I have following structure mypool/HOME mounts /home mypool/HOME/root mounts /root mypool/ROOT mounts none mypool/ROOT/rootfs mounts / mypool/ROOT/rootfs/OPT mounts /opt mypool/ROOT/rootfs/USR mounts /usr mypool/ROOT/rootfs/VAR mounts /var mypool/docker mounts /var/lib/docker

I want to backup all of this by cron task when I run zfs snapshot -r mypool/HOME@today, it creates snapshot recursively. But after I copy something heavy to /home, and create another snapshot, it shows used 0 or a few kb.

I want to be sure, that it backups mypool/HOME and mypool/HOME/root. is the -r option works for both?

Same with docker. Docker have own snapshots/clones/subvolumes on it's volume. If I do zfs snapshot -r mypool/docker, will it backup all data as it is on this moment? If some subvolumes appear/disappear, can I restore the same state it was from snapshot?

Thanks