`stress-ng --timeout 0 --vm 1` exits immediately
1sixth opened this issue · comments
The documentation says
A 0 timeout will run stress-ng for ever with no timeout.
So I expect stress-ng --timeout 0 --vm 1
to run forever, but it just exits immediately:
$ stress-ng --version
stress-ng, version 0.16.05 (gcc 12.3.0, x86_64 Linux 6.5.5) 💻🔥
$ stress-ng --timeout 0 --vm 1
stress-ng: info: [176348] setting to a 0 secs run per stressor
stress-ng: info: [176348] dispatching hogs: 1 vm
stress-ng: info: [176348] skipped: 0
stress-ng: info: [176348] passed: 1: vm (1)
stress-ng: info: [176348] failed: 0
stress-ng: info: [176348] metrics untrustworthy: 0
stress-ng: info: [176348] successful run completed in 0.01 secs
$ stress-ng --timeout 0 --cpu 1
stress-ng: info: [198210] setting to a 0 secs run per stressor
stress-ng: info: [198210] dispatching hogs: 1 cpu
# runs forever
This was introduced in 39d337d. Reverting that commit fixes the issue, though I'm not sure if it's the best way to do this.
Thanks for reporting this and finding the bad commit. Fix committed.