1What: /sys/block/<disk>/stat 2Date: February 2008 3Contact: Jerome Marchand <jmarchan@redhat.com> 4Description: 5 The /sys/block/<disk>/stat files displays the I/O 6 statistics of disk <disk>. They contain 11 fields: 7 8 == ============================================== 9 1 reads completed successfully 10 2 reads merged 11 3 sectors read 12 4 time spent reading (ms) 13 5 writes completed 14 6 writes merged 15 7 sectors written 16 8 time spent writing (ms) 17 9 I/Os currently in progress 18 10 time spent doing I/Os (ms) 19 11 weighted time spent doing I/Os (ms) 20 12 discards completed 21 13 discards merged 22 14 sectors discarded 23 15 time spent discarding (ms) 24 16 flush requests completed 25 17 time spent flushing (ms) 26 == ============================================== 27 28 For more details refer Documentation/admin-guide/iostats.rst 29 30 31What: /sys/block/<disk>/diskseq 32Date: February 2021 33Contact: Matteo Croce <mcroce@microsoft.com> 34Description: 35 The /sys/block/<disk>/diskseq files reports the disk 36 sequence number, which is a monotonically increasing 37 number assigned to every drive. 38 Some devices, like the loop device, refresh such number 39 every time the backing file is changed. 40 The value type is 64 bit unsigned. 41 42 43What: /sys/block/<disk>/<part>/stat 44Date: February 2008 45Contact: Jerome Marchand <jmarchan@redhat.com> 46Description: 47 The /sys/block/<disk>/<part>/stat files display the 48 I/O statistics of partition <part>. The format is the 49 same as the above-written /sys/block/<disk>/stat 50 format. 51 52 53What: /sys/block/<disk>/integrity/format 54Date: June 2008 55Contact: Martin K. Petersen <martin.petersen@oracle.com> 56Description: 57 Metadata format for integrity capable block device. 58 E.g. T10-DIF-TYPE1-CRC. 59 60 61What: /sys/block/<disk>/integrity/read_verify 62Date: June 2008 63Contact: Martin K. Petersen <martin.petersen@oracle.com> 64Description: 65 Indicates whether the block layer should verify the 66 integrity of read requests serviced by devices that 67 support sending integrity metadata. 68 69 70What: /sys/block/<disk>/integrity/tag_size 71Date: June 2008 72Contact: Martin K. Petersen <martin.petersen@oracle.com> 73Description: 74 Number of bytes of integrity tag space available per 75 512 bytes of data. 76 77 78What: /sys/block/<disk>/integrity/device_is_integrity_capable 79Date: July 2014 80Contact: Martin K. Petersen <martin.petersen@oracle.com> 81Description: 82 Indicates whether a storage device is capable of storing 83 integrity metadata. Set if the device is T10 PI-capable. 84 85What: /sys/block/<disk>/integrity/protection_interval_bytes 86Date: July 2015 87Contact: Martin K. Petersen <martin.petersen@oracle.com> 88Description: 89 Describes the number of data bytes which are protected 90 by one integrity tuple. Typically the device's logical 91 block size. 92 93What: /sys/block/<disk>/integrity/write_generate 94Date: June 2008 95Contact: Martin K. Petersen <martin.petersen@oracle.com> 96Description: 97 Indicates whether the block layer should automatically 98 generate checksums for write requests bound for 99 devices that support receiving integrity metadata. 100 101What: /sys/block/<disk>/alignment_offset 102Date: April 2009 103Contact: Martin K. Petersen <martin.petersen@oracle.com> 104Description: 105 Storage devices may report a physical block size that is 106 bigger than the logical block size (for instance a drive 107 with 4KB physical sectors exposing 512-byte logical 108 blocks to the operating system). This parameter 109 indicates how many bytes the beginning of the device is 110 offset from the disk's natural alignment. 111 112What: /sys/block/<disk>/<partition>/alignment_offset 113Date: April 2009 114Contact: Martin K. Petersen <martin.petersen@oracle.com> 115Description: 116 Storage devices may report a physical block size that is 117 bigger than the logical block size (for instance a drive 118 with 4KB physical sectors exposing 512-byte logical 119 blocks to the operating system). This parameter 120 indicates how many bytes the beginning of the partition 121 is offset from the disk's natural alignment. 122 123What: /sys/block/<disk>/queue/logical_block_size 124Date: May 2009 125Contact: Martin K. Petersen <martin.petersen@oracle.com> 126Description: 127 This is the smallest unit the storage device can 128 address. It is typically 512 bytes. 129 130What: /sys/block/<disk>/queue/physical_block_size 131Date: May 2009 132Contact: Martin K. Petersen <martin.petersen@oracle.com> 133Description: 134 This is the smallest unit a physical storage device can 135 write atomically. It is usually the same as the logical 136 block size but may be bigger. One example is SATA 137 drives with 4KB sectors that expose a 512-byte logical 138 block size to the operating system. For stacked block 139 devices the physical_block_size variable contains the 140 maximum physical_block_size of the component devices. 141 142What: /sys/block/<disk>/queue/minimum_io_size 143Date: April 2009 144Contact: Martin K. Petersen <martin.petersen@oracle.com> 145Description: 146 Storage devices may report a granularity or preferred 147 minimum I/O size which is the smallest request the 148 device can perform without incurring a performance 149 penalty. For disk drives this is often the physical 150 block size. For RAID arrays it is often the stripe 151 chunk size. A properly aligned multiple of 152 minimum_io_size is the preferred request size for 153 workloads where a high number of I/O operations is 154 desired. 155 156What: /sys/block/<disk>/queue/optimal_io_size 157Date: April 2009 158Contact: Martin K. Petersen <martin.petersen@oracle.com> 159Description: 160 Storage devices may report an optimal I/O size, which is 161 the device's preferred unit for sustained I/O. This is 162 rarely reported for disk drives. For RAID arrays it is 163 usually the stripe width or the internal track size. A 164 properly aligned multiple of optimal_io_size is the 165 preferred request size for workloads where sustained 166 throughput is desired. If no optimal I/O size is 167 reported this file contains 0. 168 169What: /sys/block/<disk>/queue/nomerges 170Date: January 2010 171Contact: 172Description: 173 Standard I/O elevator operations include attempts to 174 merge contiguous I/Os. For known random I/O loads these 175 attempts will always fail and result in extra cycles 176 being spent in the kernel. This allows one to turn off 177 this behavior on one of two ways: When set to 1, complex 178 merge checks are disabled, but the simple one-shot merges 179 with the previous I/O request are enabled. When set to 2, 180 all merge tries are disabled. The default value is 0 - 181 which enables all types of merge tries. 182 183What: /sys/block/<disk>/discard_alignment 184Date: May 2011 185Contact: Martin K. Petersen <martin.petersen@oracle.com> 186Description: 187 Devices that support discard functionality may 188 internally allocate space in units that are bigger than 189 the exported logical block size. The discard_alignment 190 parameter indicates how many bytes the beginning of the 191 device is offset from the internal allocation unit's 192 natural alignment. 193 194What: /sys/block/<disk>/<partition>/discard_alignment 195Date: May 2011 196Contact: Martin K. Petersen <martin.petersen@oracle.com> 197Description: 198 Devices that support discard functionality may 199 internally allocate space in units that are bigger than 200 the exported logical block size. The discard_alignment 201 parameter indicates how many bytes the beginning of the 202 partition is offset from the internal allocation unit's 203 natural alignment. 204 205What: /sys/block/<disk>/queue/discard_granularity 206Date: May 2011 207Contact: Martin K. Petersen <martin.petersen@oracle.com> 208Description: 209 Devices that support discard functionality may 210 internally allocate space using units that are bigger 211 than the logical block size. The discard_granularity 212 parameter indicates the size of the internal allocation 213 unit in bytes if reported by the device. Otherwise the 214 discard_granularity will be set to match the device's 215 physical block size. A discard_granularity of 0 means 216 that the device does not support discard functionality. 217 218What: /sys/block/<disk>/queue/discard_max_bytes 219Date: May 2011 220Contact: Martin K. Petersen <martin.petersen@oracle.com> 221Description: 222 Devices that support discard functionality may have 223 internal limits on the number of bytes that can be 224 trimmed or unmapped in a single operation. Some storage 225 protocols also have inherent limits on the number of 226 blocks that can be described in a single command. The 227 discard_max_bytes parameter is set by the device driver 228 to the maximum number of bytes that can be discarded in 229 a single operation. Discard requests issued to the 230 device must not exceed this limit. A discard_max_bytes 231 value of 0 means that the device does not support 232 discard functionality. 233 234What: /sys/block/<disk>/queue/discard_zeroes_data 235Date: May 2011 236Contact: Martin K. Petersen <martin.petersen@oracle.com> 237Description: 238 Will always return 0. Don't rely on any specific behavior 239 for discards, and don't read this file. 240 241What: /sys/block/<disk>/queue/write_same_max_bytes 242Date: January 2012 243Contact: Martin K. Petersen <martin.petersen@oracle.com> 244Description: 245 Some devices support a write same operation in which a 246 single data block can be written to a range of several 247 contiguous blocks on storage. This can be used to wipe 248 areas on disk or to initialize drives in a RAID 249 configuration. write_same_max_bytes indicates how many 250 bytes can be written in a single write same command. If 251 write_same_max_bytes is 0, write same is not supported 252 by the device. 253 254What: /sys/block/<disk>/queue/write_zeroes_max_bytes 255Date: November 2016 256Contact: Chaitanya Kulkarni <chaitanya.kulkarni@wdc.com> 257Description: 258 Devices that support write zeroes operation in which a 259 single request can be issued to zero out the range of 260 contiguous blocks on storage without having any payload 261 in the request. This can be used to optimize writing zeroes 262 to the devices. write_zeroes_max_bytes indicates how many 263 bytes can be written in a single write zeroes command. If 264 write_zeroes_max_bytes is 0, write zeroes is not supported 265 by the device. 266 267What: /sys/block/<disk>/queue/zoned 268Date: September 2016 269Contact: Damien Le Moal <damien.lemoal@wdc.com> 270Description: 271 zoned indicates if the device is a zoned block device 272 and the zone model of the device if it is indeed zoned. 273 The possible values indicated by zoned are "none" for 274 regular block devices and "host-aware" or "host-managed" 275 for zoned block devices. The characteristics of 276 host-aware and host-managed zoned block devices are 277 described in the ZBC (Zoned Block Commands) and ZAC 278 (Zoned Device ATA Command Set) standards. These standards 279 also define the "drive-managed" zone model. However, 280 since drive-managed zoned block devices do not support 281 zone commands, they will be treated as regular block 282 devices and zoned will report "none". 283 284What: /sys/block/<disk>/queue/nr_zones 285Date: November 2018 286Contact: Damien Le Moal <damien.lemoal@wdc.com> 287Description: 288 nr_zones indicates the total number of zones of a zoned block 289 device ("host-aware" or "host-managed" zone model). For regular 290 block devices, the value is always 0. 291 292What: /sys/block/<disk>/queue/max_active_zones 293Date: July 2020 294Contact: Niklas Cassel <niklas.cassel@wdc.com> 295Description: 296 For zoned block devices (zoned attribute indicating 297 "host-managed" or "host-aware"), the sum of zones belonging to 298 any of the zone states: EXPLICIT OPEN, IMPLICIT OPEN or CLOSED, 299 is limited by this value. If this value is 0, there is no limit. 300 301What: /sys/block/<disk>/queue/max_open_zones 302Date: July 2020 303Contact: Niklas Cassel <niklas.cassel@wdc.com> 304Description: 305 For zoned block devices (zoned attribute indicating 306 "host-managed" or "host-aware"), the sum of zones belonging to 307 any of the zone states: EXPLICIT OPEN or IMPLICIT OPEN, 308 is limited by this value. If this value is 0, there is no limit. 309 310What: /sys/block/<disk>/queue/chunk_sectors 311Date: September 2016 312Contact: Hannes Reinecke <hare@suse.com> 313Description: 314 chunk_sectors has different meaning depending on the type 315 of the disk. For a RAID device (dm-raid), chunk_sectors 316 indicates the size in 512B sectors of the RAID volume 317 stripe segment. For a zoned block device, either 318 host-aware or host-managed, chunk_sectors indicates the 319 size in 512B sectors of the zones of the device, with 320 the eventual exception of the last zone of the device 321 which may be smaller. 322 323What: /sys/block/<disk>/queue/io_timeout 324Date: November 2018 325Contact: Weiping Zhang <zhangweiping@didiglobal.com> 326Description: 327 io_timeout is the request timeout in milliseconds. If a request 328 does not complete in this time then the block driver timeout 329 handler is invoked. That timeout handler can decide to retry 330 the request, to fail it or to start a device recovery strategy. 331