#2192 Issue closed: Cannot Backup Folder Mounted to /dev/fuse

Labels: support / question, fixed / solved / done

gaia opened issue at 2019-07-21 18:33:

  • Relax-and-Recover 2.4 / Git (installed via apt)

  • Debian 10

  • BareMetal

  • x86_64

  • UEFI + GRUB

  • Root on mdadm, NVME disk attached, rear on USB flash drive:

  • During backup, a path /etc/xyz, mounted on /dev/fuse, is not backed up by borg

  • Workaround: ?

I have exclusions set (EXCLUDE_MOUNTPOINTS, EXCLUDE_MD, EXCLUDE_VG), but none of the exclusions point to anything that uses fuse and /etc/xyz is not in the exclusion list.

I tried putting /etc/xyz in COPY_AS_IS_BORG and COPY_AS_IS.

Why can't I backup /etc/xyz on /dev/fuse?

gaia commented at 2019-07-21 18:34:

as a side question, why doesn't /home show up in /tmp/rear.xxxxxxxx/rootfs/home but it is included in the backup if I borg mount it? I have a single backup plan and single repo. I apologize if this should be a separate issue.

gozora commented at 2019-07-21 18:38:

Can you read content of /etc/xyz with user that us running ReaR session (I'm guessing root) ?
AFAIK user fuse filesystems are not directly readable by root ...

V.

gozora commented at 2019-07-21 18:49:

/tmp/rear.xxxxxxxx/rootfs normally contains only files for so called ReaR rescue system which is small "distribution" that serves only for booting your server/PC. User data for restore are not stored here but in Borg repository.

V.

gaia commented at 2019-07-21 19:10:

Can you read content of /etc/xyz with user that us running ReaR session (I'm guessing root) ?
AFAIK user fuse filesystems are not directly readable by root ...

V.

Yes, I can read /etc/xyz as root, ReaR runs as root, and borg (by itself, not via ReaR) can backup /etc/xyz

gozora commented at 2019-07-21 19:33:

hmm, then this must be somehow related to ReaR default (NETFS) include/exclude system or alternatively to your configuration. Configuring includes/excludes can quickly become complicated when messing with incorrect parameters ;-)

Can you provide your configuration (site.conf, local.conf, ...) and logfile from rear mkbackup (should be located in /var/log/rear/)?
FYI this log should have list of directories to include/exclude near the end of the file ...

V.

gaia commented at 2019-07-21 20:19:

I mutilated the URL because it is a single download file storage service and didnt want them expanded by github

log: file[.]io/QcWQ8G (zip file)

local.conf (others are empty): file[.]io/gfAT7L

gozora commented at 2019-07-21 20:29:

Do you know that you can upload files directly to github as attachment just by drag&drop ?

github.txt

V.

gozora commented at 2019-07-21 20:54:

@gaia can you also please share output mount command ?

In EXCLUDE_VG /dev/mapper/lvmt_containers1-lvmt_containers1 and /dev/mapper/lvm_storage1-lvm_storage1 looks to be logical volumes instead of volume groups, not sure if it have the desired effect for you.
Are you aware of this warning ?

V.

gaia commented at 2019-07-21 20:56:

:) yes, but I didn't want the files lingering here giving insight into my box. if others need to look at it, by all means put them up here. i will try to remind you to pls remove them once the issue is closed.

i didn't notice the warning, i will mod it to exclude the VG not the LV. but the effect is as desired: nothing there should be backed up.

sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=16393020k,nr_inodes=4098255,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /run type tmpfs (rw,nosuid,noexec,relatime,size=3283484k,mode=755)
/dev/md0 on / type ext4 (rw,relatime,errors=remount-ro)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
tmpfs on /run/lock type tmpfs (rw,nosuid,nodev,noexec,relatime,size=5120k)
tmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755)
cgroup2 on /sys/fs/cgroup/unified type cgroup2 (rw,nosuid,nodev,noexec,relatime)
cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xattr,name=systemd)
pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
bpf on /sys/fs/bpf type bpf (rw,nosuid,nodev,noexec,relatime,mode=700)
cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
cgroup on /sys/fs/cgroup/net_cls,net_prio type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls,net_prio)
cgroup on /sys/fs/cgroup/hugetlb type cgroup (rw,nosuid,nodev,noexec,relatime,hugetlb)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer)
cgroup on /sys/fs/cgroup/perf_event type cgroup (rw,nosuid,nodev,noexec,relatime,perf_event)
cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpu,cpuacct)
cgroup on /sys/fs/cgroup/pids type cgroup (rw,nosuid,nodev,noexec,relatime,pids)
cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio)
cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,memory)
cgroup on /sys/fs/cgroup/rdma type cgroup (rw,nosuid,nodev,noexec,relatime,rdma)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=33,pgrp=1,timeout=0,minproto=5,maxproto=5,direct,pipe_ino=1111)
debugfs on /sys/kernel/debug type debugfs (rw,relatime)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime,pagesize=2M)
mqueue on /dev/mqueue type mqueue (rw,relatime)
sunrpc on /run/rpc_pipefs type rpc_pipefs (rw,relatime)
fusectl on /sys/fs/fuse/connections type fusectl (rw,relatime)
configfs on /sys/kernel/config type configfs (rw,relatime)
/dev/mapper/lvm_storage1-lvm_storage1 on /mnt/storage type ext4 (rw,relatime)
/dev/sdb1 on /boot/efi type vfat (rw,relatime,fmask=0077,dmask=0077,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)
zfs_containers2 on /zfs_containers2 type zfs (rw,xattr,noacl)
lxcfs on /var/lib/lxcfs type fuse.lxcfs (rw,nosuid,nodev,relatime,user_id=0,group_id=0,allow_other)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,relatime)
/dev/fuse on /etc/pve type fuse (rw,nosuid,nodev,relatime,user_id=0,group_id=0,default_permissions,allow_other)
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=3283480k,mode=700,uid=1000,gid=1000)

gozora commented at 2019-07-21 21:13:

@gaia ah sorry about that!
Anyhow there shouldn't be anything that could compromise your security.
I can of course remove this info if this issue is resolved ...

Try to take a look here. This example is using BACKUP_PROG_INCLUDE to explicitly include btrfs subvolumes which would not backed up otherwise. Maybe it will help.

V.

gaia commented at 2019-07-21 21:40:

problem solved, thank you @gozora !


[Export of Github issue for rear/rear.]