iostat(8) says: -w Pause wait seconds between each display. If no wait interval is specified, the default is 1 second. iostat itself disagrees: iostat -xw iostat: option requires an argument -- w usage: iostat [-CdhIKoTxz?] [-c count] [-M core] [-n devs] [-N system] [-t type,if,pass] [-w wait] [drives] Suggest dropping the second sentence from the man page entry.
From r215786: Clarify a few details about iostat(8) behavior: - The default repeat count for iostat(8) is 1 unless there was a -w on the command line. The second sentence should remain, but perhaps could change to "If -w is not specified, [...]".
No not really as if -w isn't specified it doesn't do interval based display.
(In reply to Steven Hartland from comment #2) > No not really as if -w isn't specified it doesn't do interval based display. Not even if a -c count is specified?
You're correct if -c X is specified by no -w then it defaults to 1 second.
Bug 153012 is similar, and has a patch that might be useful.
The cleanups I made for vmstat.8 in r269727 might also be worth looking at.
MARKED AS SPAM
Created attachment 272080 [details] -w descripion of iostat man page rewritten/expanded Following Benjamin's suggestion (see comment #1), I've rewritten/expanded the -w explanation to reflect the behavior in combination with -c. (Halifax Hackathon 202606)
Created attachment 272086 [details] Git format patch with adjustements I think it's good to put the description first, then the flag. Also, I really really like semantic line breaks, I think they're much clearer to maintain and better for grep. How's this? I have also put it in a git-format patch, please use these in the future. If you need any help making them I'd be happy to advise!
Also thank you so much for fixing this! Merging fixes to very old bugs is incredibly satisfying. Please give my regards to our teammates in Halifax!
(In reply to Alexander Ziaee from comment #11) Thanks for pointing me to git format-patch; I wasn't familiar with it, but I'll definitely use it in the future. I like your patch suggestion, and I'll implement it in future patches likewise. Greetings back from the Halifax Hackathon team!
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=4d299a767acce2841ded288e789a9c36620b57d7 commit 4d299a767acce2841ded288e789a9c36620b57d7 Author: Mathias Eggers <mathias.eggers@proton.me> AuthorDate: 2026-06-23 20:09:24 +0000 Commit: Alexander Ziaee <ziaee@FreeBSD.org> CommitDate: 2026-06-25 02:57:34 +0000 iostat.8: Expand -w description PR: 194781 MFC after: 3 days Reviewed by: ziaee Event: Halifax Hackathon 202606 usr.sbin/iostat/iostat.8 | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-)
A patch was committed that fixes the issue. I'm closing this PR. Thanks for filing it and sorry it took so long.
A commit in branch stable/15 references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=62551ae38bf201654ebf2ffd59cb320ac75107a0 commit 62551ae38bf201654ebf2ffd59cb320ac75107a0 Author: Mathias Eggers <mathias.eggers@proton.me> AuthorDate: 2026-06-23 20:09:24 +0000 Commit: Alexander Ziaee <ziaee@FreeBSD.org> CommitDate: 2026-06-28 00:38:12 +0000 iostat.8: Expand -w description PR: 194781 MFC after: 3 days Reviewed by: ziaee Event: Halifax Hackathon 202606 (cherry picked from commit 4d299a767acce2841ded288e789a9c36620b57d7) usr.sbin/iostat/iostat.8 | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-)
A commit in branch stable/14 references this bug: URL: https://cgit.FreeBSD.org/src/commit/?id=2abf4ce4d799d84112402867229c7d5bb4f81a90 commit 2abf4ce4d799d84112402867229c7d5bb4f81a90 Author: Mathias Eggers <mathias.eggers@proton.me> AuthorDate: 2026-06-23 20:09:24 +0000 Commit: Alexander Ziaee <ziaee@FreeBSD.org> CommitDate: 2026-08-06 22:30:35 +0000 iostat.8: Expand -w description PR: 194781 MFC after: 3 days Reviewed by: ziaee Event: Halifax Hackathon 202606 (cherry picked from commit 4d299a767acce2841ded288e789a9c36620b57d7) usr.sbin/iostat/iostat.8 | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-)