Lines Matching full:stat

30 #   kstat [-g] <stat>
31 # kstat_pool [-g] <pool> <stat>
32 # kstat_dataset [-N] <dataset | pool/objsetid> <stat>
34 # `kstat` and `kstat_pool` return the value of of the given <stat>, either
46 # To get a single stat within a group or collection, separate the name with
56 # group are returned, one stat per line, key and value separated by a space.
88 # kstat [-g] <stat>
103 typeset stat=$1
105 $_kstat_os 'global' '' "$stat" $want_group
109 # kstat_pool [-g] <pool> <stat>
125 typeset stat=$2
127 $_kstat_os 'pool' "$pool" "$stat" $want_group
131 # kstat_dataset [-N] <dataset | pool/objsetid> <stat>
147 typeset stat=$2
158 $_kstat_os 'dataset' "$dsarg" "$stat" 0
172 # _kstat_freebsd <scope> <object> <stat> <want_group>
173 # _kstat_linux <scope> <object> <stat> <want_group>
181 # - stat: kstat name to get
183 # as a group and get all the stat names+values under it. group
184 # kstats cannot have values, and stat kstats cannot have
187 # Stat values can have multiple lines, so be prepared for those.
194 # - want_group=0: the single stat value, followed by newline
195 # - want_group=1: One stat per line, <name><SP><value><newline>
216 # in the stat tree, which are normally opaque. Because sysctl has no filtering
219 # if we got a group or a single stat, and post-process accordingly.
226 # _kstat_freebsd <scope> <object> <stat> <want_group>
232 typeset stat=$3
238 oid="kstat.zfs.misc.$stat"
245 case "$stat" in
247 oid="kstat.zfs.$obj.$stat"
250 oid="kstat.zfs.$obj.misc.$stat"
259 $pool $objsetid $stat)
329 # Groups are challenge. A single stat can be the entire text of a file, or
337 # _kstat_linux <scope> <object> <stat> <want_group>
343 typeset stat=$3
352 stat=$(printf 'objset-0x%x.%s' $objsetid $stat)
359 path="/proc/spl/kstat/zfs/$stat"
361 path="/proc/spl/kstat/zfs/$obj/$stat"
365 # This single stat doesn't have its own file, but the wanted
366 # stat could be in a group kstat file, which we now need to
367 # find. To do this, we split a single stat name into two parts:
368 # the file that would contain the stat, and the key within that
381 typeset -a split=($(echo "$stat" | \
415 # single stat. must be a single line within a group stat, so
425 # raw stat. dump contents, exclude group stats
437 3) log_fail "kstat: stat not found in group: $path $singlestat" ;;