Summary: | zfs list USEDSNAP, USEDDS no longer seem to work on RELENG_14 | ||
---|---|---|---|
Product: | Base System | Reporter: | mike |
Component: | kern | Assignee: | Mark Johnston <markj> |
Status: | Closed FIXED | ||
Severity: | Affects Only Me | CC: | cy, emaste, jamie, markj, pi, tom |
Priority: | --- | Keywords: | regression |
Version: | 14.0-STABLE | ||
Hardware: | Any | ||
OS: | Any |
Description
mike
2023-10-20 16:02:10 UTC
Note, this image was installed from https://download.freebsd.org/releases/VM-IMAGES/14.0-RC1/amd64/Latest/FreeBSD-14.0-RC1-amd64-zfs.raw.xz Do you see the same problem if you create the pool yourself on 14, i.e., without using the pool created by makefs as part of VM image creation? (In reply to Mark Johnston from comment #2) WOW, good catch! from history 361 12:48 truncate -s 100M /tmp/a 362 12:49 mdconfig -f /tmp/a 363 12:49 gpart create -s gpt /dev/md0 364 12:49 gpart add -t freebsd-zfs /dev/md0 365 12:49 zpool create testpool /dev/md0p1 370 12:50 dd if=/dev/urandom of=/testpool/junk count=1 371 12:50 zfs snapshot -r testpool@test1 372 12:51 rm /testpool/junk # zfs list -p -o name,avail,used,usedsnap,usedds testpool NAME AVAIL USED USEDSNAP USEDDS testpool 41779200 163840 14848 24576 zfs get all testpool NAME PROPERTY VALUE SOURCE testpool type filesystem - testpool creation Fri Oct 20 12:49 2023 - testpool used 160K - testpool available 39.8M - testpool referenced 24K - testpool compressratio 1.00x - testpool mounted yes - testpool quota none default testpool reservation none default testpool recordsize 128K default testpool mountpoint /testpool default testpool sharenfs off default testpool checksum on default testpool compression on default testpool atime on default testpool devices on default testpool exec on default testpool setuid on default testpool readonly off default testpool jailed off default testpool snapdir hidden default testpool aclmode discard default testpool aclinherit restricted default testpool createtxg 1 - testpool canmount on default testpool xattr on default testpool copies 1 default testpool version 5 - testpool utf8only off - testpool normalization none - testpool casesensitivity sensitive - testpool vscan off default testpool nbmand off default testpool sharesmb off default testpool refquota none default testpool refreservation none default testpool guid 12863139616279728335 - testpool primarycache all default testpool secondarycache all default testpool usedbysnapshots 14.5K - testpool usedbydataset 24K - testpool usedbychildren 122K - testpool usedbyrefreservation 0B - testpool logbias latency default testpool objsetid 54 - testpool dedup off default testpool mlslabel none default testpool sync standard default testpool dnodesize legacy default testpool refcompressratio 1.00x - testpool written 14K - testpool logicalused 60K - testpool logicalreferenced 12K - testpool volmode default default testpool filesystem_limit none default testpool snapshot_limit none default testpool filesystem_count none default testpool snapshot_count none default testpool snapdev hidden default testpool acltype nfsv4 default testpool context none default testpool fscontext none default testpool defcontext none default testpool rootcontext none default testpool relatime on default testpool redundant_metadata all default testpool overlay on default testpool encryption off default testpool keylocation none default testpool keyformat none default testpool pbkdf2iters 0 default testpool special_small_blocks 0 default testpool snapshots_changed Fri Oct 20 12:50:56 2023 - # zpool status pool: testpool state: ONLINE config: NAME STATE READ WRITE CKSUM testpool ONLINE 0 0 0 md0p1 ONLINE 0 0 0 errors: No known data errors pool: zroot state: ONLINE scan: scrub repaired 0B in 00:00:18 with 0 errors on Fri Oct 20 10:05:47 2023 config: NAME STATE READ WRITE CKSUM zroot ONLINE 0 0 0 vtbd0p4 ONLINE 0 0 0 errors: No known data errors A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=96092bf9108c97b45d18fd26fbe91f2d1c7799b8 commit 96092bf9108c97b45d18fd26fbe91f2d1c7799b8 Author: Mark Johnston <markj@FreeBSD.org> AuthorDate: 2023-10-23 15:08:04 +0000 Commit: Mark Johnston <markj@FreeBSD.org> CommitDate: 2023-10-23 15:12:14 +0000 makefs/zfs: Fill out dd_used_breakdown fields in DSL directories This is required for the "used", "usedds" and "usedchild" dataset properties to be displayed. PR: 274613 Reported by: Mike Tancsa <mike@sentex.net> MFC after: 1 week Sponsored by: The FreeBSD Foundation usr.sbin/makefs/zfs/dsl.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=9f9d18d61e74e2486d9dc0c0187eb72b02c66743 commit 9f9d18d61e74e2486d9dc0c0187eb72b02c66743 Author: Mark Johnston <markj@FreeBSD.org> AuthorDate: 2023-10-23 15:11:26 +0000 Commit: Mark Johnston <markj@FreeBSD.org> CommitDate: 2023-10-23 15:15:00 +0000 makefs/zfs: Add a regression test which checks the 'used*' properties PR: 274613 MFC after: 1 week Sponsored by: The FreeBSD Foundation usr.sbin/makefs/tests/makefs_zfs_tests.sh | 73 ++++++++++++++++++++++++++++++- 1 file changed, 71 insertions(+), 2 deletions(-) So this will be fixed in images created by a patched makefs, but existing images will still have the problem. I believe that the problem only occurs in datasets created by makefs, not in datasets created after the image is booted, even if they belong to the same pool. So you could conceivably work around the problem in an affected image by creating new datasets and copying everything over. A commit in branch stable/14 references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=eb5cbd793e31f9d656999033be54dac1a1107294 commit eb5cbd793e31f9d656999033be54dac1a1107294 Author: Mark Johnston <markj@FreeBSD.org> AuthorDate: 2023-10-23 15:08:04 +0000 Commit: Mark Johnston <markj@FreeBSD.org> CommitDate: 2023-10-25 14:27:27 +0000 makefs/zfs: Fill out dd_used_breakdown fields in DSL directories This is required for the "used", "usedds" and "usedchild" dataset properties to be displayed. PR: 274613 Reported by: Mike Tancsa <mike@sentex.net> MFC after: 1 week Sponsored by: The FreeBSD Foundation usr.sbin/makefs/zfs/dsl.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) A commit in branch stable/14 references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=cfcb53e1a132932bf3d22e87e47e38e64b118c4a commit cfcb53e1a132932bf3d22e87e47e38e64b118c4a Author: Mark Johnston <markj@FreeBSD.org> AuthorDate: 2023-10-23 15:11:26 +0000 Commit: Mark Johnston <markj@FreeBSD.org> CommitDate: 2023-10-25 14:27:27 +0000 makefs/zfs: Add a regression test which checks the 'used*' properties PR: 274613 MFC after: 1 week Sponsored by: The FreeBSD Foundation usr.sbin/makefs/tests/makefs_zfs_tests.sh | 73 ++++++++++++++++++++++++++++++- 1 file changed, 71 insertions(+), 2 deletions(-) I believe this is fixed now: root@freebsd:~ # zfs list -p -o name,used,usedds,usedchild,usedsnap NAME USED USEDDS USEDCHILD USEDSNAP zroot 3889631232 434176 3889197056 0 zroot/ROOT 3880652800 434176 3880218624 0 zroot/ROOT/default 3880218624 3880218624 0 0 zroot/home 430080 430080 0 0 zroot/tmp 430080 430080 0 0 zroot/usr 1724416 434176 1290240 0 zroot/usr/obj 430080 430080 0 0 zroot/usr/ports 430080 430080 0 0 zroot/usr/src 430080 430080 0 0 zroot/var 2273280 434176 1839104 0 zroot/var/audit 438272 438272 0 0 zroot/var/log 536576 536576 0 0 zroot/var/mail 430080 430080 0 0 zroot/var/tmp 434176 434176 0 0 A commit in branch releng/14.0 references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=60bc03c9c36aa38204e862269f13bf79ded72119 commit 60bc03c9c36aa38204e862269f13bf79ded72119 Author: Mark Johnston <markj@FreeBSD.org> AuthorDate: 2023-10-23 15:08:04 +0000 Commit: Mark Johnston <markj@FreeBSD.org> CommitDate: 2023-10-25 16:55:52 +0000 makefs/zfs: Fill out dd_used_breakdown fields in DSL directories This is required for the "used", "usedds" and "usedchild" dataset properties to be displayed. Approved by: re (gjb) PR: 274613 Reported by: Mike Tancsa <mike@sentex.net> MFC after: 1 week Sponsored by: The FreeBSD Foundation (cherry picked from commit eb5cbd793e31f9d656999033be54dac1a1107294) usr.sbin/makefs/zfs/dsl.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) |