K 10 svn:author V 9 allanjude K 8 svn:date V 27 2020-09-19T20:46:56.392769Z K 7 svn:log V 1447 MFS r365689,r365808,r365860 MFOpenZFS: Introduce read/write kstats per dataset The following patch introduces a few statistics on reads and writes grouped by dataset. These statistics are implemented as kstats (backed by aggregate sums for performance) and can be retrieved by using the dataset objset ID number. The motivation for this change is to provide some preliminary analytics on dataset usage/performance. Reviewed-by: Richard Elling Reviewed-by: Brian Behlendorf Reviewed by: Matthew Ahrens Signed-off-by: Serapheim Dimitropoulos openzfs/zfs@a448a2557ec4938ed6944c7766fe0b8e6e5f6456 Also contains parts of: MFOpenZFS: Connect dataset_kstats for FreeBSD Example output: kstat.zfs.mypool.dataset.objset-0x10b.nread: 150528 kstat.zfs.mypool.dataset.objset-0x10b.reads: 48 kstat.zfs.mypool.dataset.objset-0x10b.nwritten: 134217728 kstat.zfs.mypool.dataset.objset-0x10b.writes: 1024 kstat.zfs.mypool.dataset.objset-0x10b.dataset_name: mypool/datasetname Reviewed-by: Ryan Moeller Reviewed by: Sean Eric Fagan Reviewed-by: Serapheim Dimitropoulos Reviewed-by: Brian Behlendorf Signed-off-by: Allan Jude openzfs/zfs@4547fc4e071ceb1818b3a46c3035b923e06e5390 Approved by: re (gjb) Relnotes: yes Sponsored by: Klara Inc. END