From nobody Sat Mar 05 23:00:08 2022 X-Original-To: bugs@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 02DAB19FA59D for ; Sat, 5 Mar 2022 23:00:09 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4KB0YN5RwMz4njw for ; Sat, 5 Mar 2022 23:00:08 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 914021033 for ; Sat, 5 Mar 2022 23:00:08 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 225N08O3088672 for ; Sat, 5 Mar 2022 23:00:08 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 225N08FH088671 for bugs@FreeBSD.org; Sat, 5 Mar 2022 23:00:08 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: bugs@FreeBSD.org Subject: [Bug 262370] nullfs mounting a unionfs shows duplicate entries from each layer Date: Sat, 05 Mar 2022 23:00:08 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: 13.0-RELEASE X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Some People X-Bugzilla-Who: chadf@triularity.org X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: bugs@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: Bug reports List-Archive: https://lists.freebsd.org/archives/freebsd-bugs List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-bugs@freebsd.org MIME-Version: 1.0 ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1646521208; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=u6RBA2nYOnTn7d5S47QoDe9L4W86n46v/gy1yuSnArw=; b=swqVjmBOjojrclqRF9bVXYZCg9ve/fiGyW52LYSKZtmM7l1sVyJvyu1nU+5PgMDhCGfvbY NTncSYpJasclEkzc5ciAmhT4mpdbjfz1P7LqvhI4qKT38DfaWfJkjlcpvIHTCUKHyA54BK PQCcqxBIeP2Iny7xyCQ441ge50Dm0QUeO8AhniP6jE0WiMRKIrVlW+QekqTo4angWhNpWl RtOccAJE9LELo3j6YRJECkN0BeJ9Od61pbp2VIuE1zmvppkjvGouqEEAYyWEG/1RPAnij1 3nszLRHJW//gR906aK5TnefaRmoMIoiddaAbsMu/riuQhKMAg22k2uVkiD2aCg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1646521208; a=rsa-sha256; cv=none; b=jtT/U1Z7Op9fsp5qjeNlgZwG2oWKpQg7wVoT8dbvWl1reGt235rtDT/R5XRoSqAvTJsRhQ zN/z6HntYIRplT6Svwewd9Oxik7hdjMTcYYA3Ch3b2eZrJrQDUhf/SQ07PpesbdrxdbZG4 542WKFeE2+3X9H6Oqk1tf16smgYs7G1w6lhljB2LqGeR6XChnD8b/TrRJG/tEoNwuo4Bs1 x71+F5U9HZ2BWMkRo/+gbaAErYSiVZ7wQfn4tacyHIipeJp+iNxqFlNNZZMQL8PvaheGwT 5Y/lskRkX8Zs3cjEfWKh3Q0oK1c6SV6tXpRFclMSH3JMUZdIpu4md2ekNnxTaQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D262370 Bug ID: 262370 Summary: nullfs mounting a unionfs shows duplicate entries from each layer Product: Base System Version: 13.0-RELEASE Hardware: Any OS: Any Status: New Severity: Affects Some People Priority: --- Component: kern Assignee: bugs@FreeBSD.org Reporter: chadf@triularity.org nullfs mounting a unionfs mount point lists the underlying [duplicate] entr= ies for each union layer. Bug exists in [at least] 12.3-RELEASE and 13.0-RELEASE (amd64). #### Example Setup mkdir /broken mkdir /broken/layer1 mkdir /broken/layer2 mkdir /broken/layer3 mkdir /broken/union-mnt mkdir /broken/null-of-union-mnt mkdir /broken/layer1/a mkdir /broken/layer1/b mkdir /broken/layer1/c mkdir /broken/layer1/d mkdir /broken/layer1/e # Could be any mount type (e.g. NFS, cd9660, etc) mount_nullfs /broken/layer1 /broken/union-mnt # Add second layer mount_unionfs /broken/layer2 /broken/union-mnt # Trigger shadow directory creations (on layer 2) ls /broken/union-mnt/a # Add third layer mount_unionfs /broken/layer3 /broken/union-mnt # Trigger shadow directory creations (on layer 3) ls /broken/union-mnt/a # null mount the union somewhere mount_nullfs /broken/union-mnt /broken/null-of-union-mnt #### union looks as expected (unified) ls /broken/union-mnt a b c d e #### nullfs of union shows duplicates ls /broken/null-of-union-mnt a a a b c d e #### Trigger more shadow copies and list again ls /broken/union-mnt/c ls /broken/null-of-union-mnt a a a b c c c d e #### Teardown umount /broken/null-of-union-mnt umount /broken/union-mnt umount /broken/union-mnt umount /broken/union-mnt rmdir /broken/null-of-union-mnt rmdir /broken/union-mnt rmdir /broken/layer1/[a-z] rmdir /broken/layer1 rmdir /broken/layer2/[a-z] rmdir /broken/layer2 rmdir /broken/layer3/[a-z] rmdir /broken/layer3 rmdir /broken ###### These duplicates also show up in a jail using a nullfs mount (of a unionfs). Unless otherwise verified, it should be assumed such a jail might have dire= ct access to the underlying unionfs layers. --=20 You are receiving this mail because: You are the assignee for the bug.=