| Summary: | kstat.zfs sysctl tree unreachable for pools with "." in the name | ||
|---|---|---|---|
| Product: | Base System | Reporter: | Alan Somers <asomers> |
| Component: | kern | Assignee: | Alan Somers <asomers> |
| Status: | Closed FIXED | ||
| Severity: | Affects Many People | CC: | fs |
| Priority: | --- | Flags: | asomers:
mfc-stable13+
asomers: mfc-stable12+ asomers: mfc-stable11- |
| Version: | 13.0-RELEASE | ||
| Hardware: | Any | ||
| OS: | Any | ||
| URL: | https://reviews.freebsd.org/D31265 | ||
|
Description
Alan Somers
2021-07-21 17:42:39 UTC
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=6c9506559080da2914749bf611225d7c0a153609 commit 6c9506559080da2914749bf611225d7c0a153609 Author: Alan Somers <asomers@FreeBSD.org> AuthorDate: 2021-07-21 21:11:00 +0000 Commit: Alan Somers <asomers@FreeBSD.org> CommitDate: 2021-07-22 16:22:48 +0000 Escape any '.' characters in sysctl node names ZFS creates some sysctl nodes that include a pool name, and '.' is an allowed character in pool names. But it's the separator in the sysctl tree, so it can't be included in a sysctl name. Replace it with "%25". Handily, "%" is illegal in ZFS pool names, so there's no ambiguity there. PR: 257316 MFC after: 3 weeks Sponsored by: Axcient Reviewed by: freqlabs Differential Revision: https://reviews.freebsd.org/D31265 sys/kern/kern_sysctl.c | 48 ++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 46 insertions(+), 2 deletions(-) A commit in branch stable/13 references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=e7d99efb3638b71756da8033ef8cef74213c42fd commit e7d99efb3638b71756da8033ef8cef74213c42fd Author: Alan Somers <asomers@FreeBSD.org> AuthorDate: 2021-07-21 21:11:00 +0000 Commit: Alan Somers <asomers@FreeBSD.org> CommitDate: 2021-08-22 21:11:00 +0000 Escape any '.' characters in sysctl node names ZFS creates some sysctl nodes that include a pool name, and '.' is an allowed character in pool names. But it's the separator in the sysctl tree, so it can't be included in a sysctl name. Replace it with "%25". Handily, "%" is illegal in ZFS pool names, so there's no ambiguity there. PR: 257316 Sponsored by: Axcient Reviewed by: freqlabs Differential Revision: https://reviews.freebsd.org/D31265 (cherry picked from commit 6c9506559080da2914749bf611225d7c0a153609) sys/kern/kern_sysctl.c | 48 ++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 46 insertions(+), 2 deletions(-) A commit in branch stable/12 references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=98c467192082b3d4a6c91eeaa80868bb5231534c commit 98c467192082b3d4a6c91eeaa80868bb5231534c Author: Alan Somers <asomers@FreeBSD.org> AuthorDate: 2021-07-21 21:11:00 +0000 Commit: Alan Somers <asomers@FreeBSD.org> CommitDate: 2021-08-22 22:43:50 +0000 Escape any '.' characters in sysctl node names ZFS creates some sysctl nodes that include a pool name, and '.' is an allowed character in pool names. But it's the separator in the sysctl tree, so it can't be included in a sysctl name. Replace it with "%25". Handily, "%" is illegal in ZFS pool names, so there's no ambiguity there. PR: 257316 Sponsored by: Axcient Reviewed by: freqlabs Differential Revision: https://reviews.freebsd.org/D31265 (cherry picked from commit 6c9506559080da2914749bf611225d7c0a153609) sys/kern/kern_sysctl.c | 47 +++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 45 insertions(+), 2 deletions(-) Not MFCing to stable/11 because stable/11 doesn't create the kstat.zfs.<pool> sysctls. |