SG_RESET_WP(8)
β¨ SG_RESET_WP(8) β¨
okay bestie, this is the SG_RESET_WP(8) manual page from SG3_UTILS π it's the guide for the sg_reset_wp tool, and it's honestly so useful π«Ά
π NAME π
sg_reset_wp β send a SCSI RESET WRITE POINTER command π¦
πΈ SYNOPSIS πΈ
sg_reset_wp [--all] [--count=ZC] [--help] [--verbose] [--version]
[--zone=ID] DEVICE
π DESCRIPTION π
okay so this tool sends a SCSI RESET WRITE POINTER command to your DEVICE π₯ the command is described in the ZBC standard (INCITS 536-2016) and in the draft ZBC-2 documents over at T10, like zbc2r12.pdf. literally the source of truth, no cap β¨
β¨ OPTIONS β¨
quick heads up: arguments to long options are mandatory for short options as well π
-a,--allβ this sets the ALL field in the cdb, so the reset hits every open zone and every full zone π if you use this, then any--zone=IDyou pass gets ignored (rude, but that's the rule). you need either this or--zone=ID, one of them is required, periodt π-C,--count=ZCβ ZC goes into the Zone Count field of the cdb for the RESET WRITE POINTER command. ZC should be somewhere from 0 to 65535 (0xffff), inclusive π what the DEVICE actually does with it depends on whether--allis set too. for the full tea, check the RESET WRITE POINTER command description (section 5.9, table 46 in zbc2r12.pdf) π§-h,--helpβ prints the usage message and then exits π-v,--verboseβ bumps up the verbosity level, so you get extra debug output π-V,--versionβ prints the version string and then exits π-z,--zone=IDβ ID gets placed in the cdb's ZONE ID field. a zone id is a zone start logical block address (LBA), and this triggers a reset write pointer on whatever zone has that ZONE ID β¨ the default value is 0. you need either this or--all, so don't forget π«Ά ID is decimal by default, but if you prefix it with0xor stick a trailinghon it, it's read as hexadecimal instead π¦
π NOTES π
the Zones Emptied log parameter in the Zoned Block Device Statistics log page keeps count of how many times RESET WRITE POINTER has been (successfully) invoked π so it's basically the scoreboard π
πͺ EXIT STATUS πͺ
the exit status of sg_reset_wp is 0 when it works π otherwise, go check the sg3_utils(8) man page π«Ά
π©βπ» AUTHORS π©βπ»
written by Douglas Gilbert, the legend himself π
π REPORTING BUGS π
if something's broken, report it to <dgilbert at interlog dot com> π
βοΈ COPYRIGHT βοΈ
Copyright Β© 2014-2022 Douglas Gilbert πΈ this software is distributed under a BSD-2-Clause license. there is NO warranty, not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE, so use your best judgment π
π SEE ALSO π
sg_rep_zones,sg_zone(sg3_utils) β¨
okay that's the whole tea, bestie π«Ά from sg3_utils-1.48, February 2022, with SG_RESET_WP(8) energy forever ππ¦π
π¦ where this page comes from
- alpine 3.24: sg3_utils-doc 1.48-r0 Β· BSD-2-Clause AND GPL-2.0-or-later
- arch rolling: sg3_utils 1.49-1 Β· GPL-2.0-or-later AND BSD-2-Clause
- centos-stream 10: sg3_utils 1.48-11.el10 Β· GPL-2.0-or-later AND BSD-2-Clause
- debian trixie: sg3-utils 1.48-3~deb13u1
- fedora 43: sg3_utils 1.48-10.fc43 Β· GPL-2.0-or-later AND BSD-2-Clause
- fedora 43: sg3_utils 1.48-6.fc43 Β· GPL-2.0-or-later AND BSD-2-Clause
- fedora 44: sg3_utils 1.48-10.fc44 Β· GPL-2.0-or-later AND BSD-2-Clause
- fedora 44: sg3_utils 1.48-8.fc44 Β· GPL-2.0-or-later AND BSD-2-Clause
- nixos 26.05: sg3_utils 1.48
- nixpkgs unstable: sg3_utils 1.49
- ubuntu questing: sg3-utils 1.48-2ubuntu1
- ubuntu resolute: sg3-utils 1.48-3ubuntu3
- ubuntu resolute: sg3-utils 1.48-3ubuntu3.2
- ubuntu stonking: sg3-utils 1.48-3ubuntu5
- π girlified by anthropic/claude-haiku-5.5 on : a language model's rewrite of the original, under its terms