summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: aee87d9)
raw | patch | inline | side by side (parent: aee87d9)
author | Jan Andres <jandres@gmx.net> | |
Wed, 28 Jan 2015 14:06:04 +0000 (15:06 +0100) | ||
committer | Marc Fournier <marc.fournier@camptocamp.com> | |
Tue, 19 May 2015 15:42:34 +0000 (17:42 +0200) |
The value got lost with some patch to Solaris 10 and has only reappeared
recently in 11.2. If we ever fail to read this value, stop trying, so we
don't report an error on every interval.
recently in 11.2. If we ever fail to read this value, stop trying, so we
don't report an error on every interval.
src/zfs_arc.c | patch | blob | history |
diff --git a/src/zfs_arc.c b/src/zfs_arc.c
index cc988625b32178a005222befd9dccae0898270e5..311a718125bd7d1c7c5dba61606714b0a00cca55 100644 (file)
--- a/src/zfs_arc.c
+++ b/src/zfs_arc.c
/* Sizes */
za_read_gauge (ksp, "size", "cache_size", "arc");
- za_read_gauge (ksp, "l2_size", "cache_size", "L2");
+
+ /* The "l2_size" value has disappeared from Solaris some time in
+ * early 2013, and has only reappeared recently in Solaris 11.2.
+ * Stop trying if we ever fail to read it, so we don't spam the log.
+ */
+ static int l2_size_avail = 1;
+ if (l2_size_avail && za_read_gauge (ksp, "l2_size", "cache_size", "L2") != 0)
+ l2_size_avail = 0;
/* Operations */
za_read_derive (ksp, "deleted", "cache_operation", "deleted");