Public bug reported:

tsmsrvi and tsmsrvj both run Ubuntu 20.04 with all updates applied.
When I try to access a btrfs filesystem via nfs, I get the error:

root@tsmsrvi:~# mount tsmsrvj:/data/fex /nfs/tsmsrvj/fex

root@tsmsrvi:~# find /nfs/tsmsrvj/fex
/nfs/tsmsrvj/fex
find: File system loop detected; '/nfs/tsmsrvj/fex/spool' is part of the same 
file system loop as '/nfs/tsmsrvj/fex'.

root@tsmsrvi:~# du -s /nfs/tsmsrvj/fex
du: WARNING: Circular directory structure.
This almost certainly means that you have a corrupted file system.
NOTIFY YOUR SYSTEM MANAGER.
The following directory is part of the cycle:
  /nfs/tsmsrvj/fex/spool

0       /nfs/tsmsrvj/fex

root@tsmsrvi:~# ls -l /nfs/tsmsrvj/fex/
total 0
drwxr-xr-x 1 fex fex 261964 Mar  7 14:53 spool

On tsmsrvj I have in /etc/exports:

/data/fex       localhost(rw,async,no_subtree_check,no_root_squash)
/data/fex       tsmsrvi(rw,async,no_subtree_check,no_root_squash)

/data/fex is a btrfs filesystem with subvolumes:

root@tsmsrvj:~# mount | grep /data
/dev/sdb1 on /data type btrfs 
(rw,relatime,space_cache,user_subvol_rm_allowed,subvolid=5,subvol=/)

root@tsmsrvj:~# btrfs subvolume list /data
ID 257 gen 35 top level 5 path fex
ID 270 gen 36 top level 257 path fex/spool
ID 271 gen 21 top level 270 path fex/spool/.snapshot/2021-03-07_1453.test
ID 272 gen 23 top level 270 path fex/spool/.snapshot/2021-03-07_1531.test
ID 273 gen 25 top level 270 path fex/spool/.snapshot/2021-03-07_1532.test
ID 274 gen 27 top level 270 path fex/spool/.snapshot/2021-03-07_1718.test


Accessing btrfs directly without nfs has no problems:

root@tsmsrvj:~# find /data/fex | wc -l
489887

root@tsmsrvj:~# lsb_release -rd
Description:    Ubuntu 20.04.2 LTS
Release:        20.04

root@tsmsrvj:# uname -a
Linux tsmsrvj 5.4.0-66-generic #74-Ubuntu SMP Wed Jan 27 22:54:38 UTC 2021 
x86_64 x86_64 x86_64 GNU/Linux

root@tsmsrvj:# btrfs version
btrfs-progs v5.4.1

root@tsmsrvj:# dpkg -l | grep nfs-
ii  nfs-common                             1:1.3.4-2.5ubuntu3.3              
amd64        NFS support files common to client and server
ii  nfs-kernel-server                      1:1.3.4-2.5ubuntu3.3              
amd64        support for NFS kernel server

** Affects: ubuntu
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1918599

Title:
  "File system loop detected" with btrfs over NFS

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+bug/1918599/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to