Score:0

`ps` reports itself as using 99% CPU

cn flag

After update to Ubuntu 23.04, I noticed that the ps command sometimes reports itself as using 99% CPU.

If you try several times, you will see something like:

$ ps -ef | grep \ p[s]
my_user    48167    7979  0 21:11 pts/0    00:00:00 ps -ef

$ ps -ef | grep \ p[s]
my_user    48169    7979 99 21:12 pts/0    00:00:00 ps -ef

Note the 99 in the second case. This does repeat every time. Most of the times you will get 0, as in the first example.

This did not happen in previous versions of Ubuntu. I have a script that ran for more than 8 years on several systems with versions ranging from 14.04 to 22.10 (LTS and non-LTS) and never noticed such a thing.

The current version of ps is 4.0.3. Linux kernel is 6.2.0.

Should this be considered as a bug or a feature?

See also another related post.

cn flag
"This did not happen in previous versions of Ubuntu." It does on my 22.04 Budgie install :)
FedKad avatar
cn flag
Trust me @Rinzwind it didn't and doesn't; I have several Ubuntu 22.04 systems. What is the version of your `ps`? What is your Linux kernel version? Did you really get the second output (with the `99`)?
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.