When you run reallynice sleep 5000 it tries to execute 5000 as a command which exits cryptically with failed to execute command!, and silently neglects to validate that sleep is not a valid nice value.
It may be prudent to make reallynice behave in a similar way as nice in which a -n flag is provided to set the nicelevel.
A further improvement to it might be to by default set a reasonably low nice value like 5 or 10 if this aforementioned -n flag is omitted. As far as I know, simply running nice sleep 6000 causes sleep 6000 to have a nice level of 10, so it's silly to make reallynice do things in a way dramatically different from that.
All that said, though, I'd like to give you a shout out for writing a post on reddit c++ about this issue as that is where i first found this, and it was a memorable way to describe nice as being crippled into being a placebo and allowed me to track the issue down again. it's surprising how little awareness the linux community at large has of this particular issue.
By the way I also brought it up today on the htop project github issues. Let's see if we get any traction there! (Edit: Merged!! woot) I think the nice column in htop becomes utterly useless now on affected systems so i'd like to get autogroup and autogroup nicelevel added as columns in htop.
When you run
reallynice sleep 5000it tries to execute5000as a command which exits cryptically withfailed to execute command!, and silently neglects to validate thatsleepis not a valid nice value.It may be prudent to make reallynice behave in a similar way as nice in which a
-nflag is provided to set the nicelevel.A further improvement to it might be to by default set a reasonably low nice value like 5 or 10 if this aforementioned
-nflag is omitted. As far as I know, simply runningnice sleep 6000causessleep 6000to have a nice level of10, so it's silly to make reallynice do things in a way dramatically different from that.All that said, though, I'd like to give you a shout out for writing a post on reddit c++ about this issue as that is where i first found this, and it was a memorable way to describe nice as being crippled into being a placebo and allowed me to track the issue down again. it's surprising how little awareness the linux community at large has of this particular issue.
By the way I also brought it up today on the
htopproject github issues. Let's see if we get any traction there! (Edit: Merged!! woot) I think the nice column in htop becomes utterly useless now on affected systems so i'd like to get autogroup and autogroup nicelevel added as columns in htop.