procs icon indicating copy to clipboard operation
procs copied to clipboard

`procs --sortd rss` doesn't show memory column

Open abitrolly opened this issue 3 years ago • 7 comments

$ procs --sortd rss
 PID:▲ User            │ TTY    CPU  MEM CPU Time │ Command                                                                                                              >
                       │        [%]  [%]          │                                                                                                                      >
 1     root            │        0.0  0.1 00:00:05 │ /usr/lib/systemd/systemd rhgb --switched-root --system --deserialize 31            

abitrolly avatar Jan 21 '22 06:01 abitrolly

rss is not shown by default. --sortd only sorts the specified column, do nothing if the column is not found. If you want it, VmRss column can be added to your configuration file. Please see the following file. https://github.com/dalance/procs/blob/master/config/large.toml

dalance avatar Jan 21 '22 06:01 dalance

I was looking for a lightweight replacement for ps and having to configure procs in addition to installation on every server I may need to inspect memory usage is too cumbersome. Unfortunately.

abitrolly avatar Jan 21 '22 12:01 abitrolly

If you want to do without config, you can procs --insert rss --sortd rss.

dalance avatar Jan 21 '22 14:01 dalance

Why not to turn on the column automatically if specified?

abitrolly avatar Jan 22 '22 08:01 abitrolly

There is no reason. I'll consider it, but I don't have the enough time to implement now.

dalance avatar Jan 24 '22 11:01 dalance

Understand. Will a PR be accepted to provide that behavior?

abitrolly avatar Jan 25 '22 03:01 abitrolly

Understand. Will a PR be accepted to provide that behavior?

Yes

dalance avatar Jan 26 '22 03:01 dalance

@dalance I have opened a PR. Any chance to get it reviewed?

sou-chon avatar Dec 08 '22 12:12 sou-chon