How can I show the CPU usage side by side rather than a list?
I have this :
but I want to show it like this:
Best Answer
Go to settings (F2), under Meters, you select what is in the left column and what in the right column. Instead of CPUs (1/1) in the left column, select CPUs (1/2) for the left column and CPUs (2/2) for the right column. F10 to save the changes and it's done.
htop is unaware it is running on a kernel level virtualized environment (Dreamhost VPS is using VServer technology). It is then showing the CPU usage for all the OS instances sharing the same kernel, not just yours.
Have a look to vtop output which sho ws all processes sharing the CPUs, not just the ones in your container.
If vtop is not installed, and this is probably expected for a commercial solution as one wouldn't like to a customer to see what processes are running other customers, there is no way to fix the issue from inside your container, unless patching top source to compute CPU usage instead of getting it from the kernel statistics.
It might do it by summing up CPU usage of all the processes running in your VServer, e.g.:
ps aux | awk '
{cpu+=$3; ram+=$6}
END {printf("cpu: %d%%, RAM: %.2f MiB\n",cpu,ram/1024) }'
Best Answer
Go to settings (F2), under Meters, you select what is in the left column and what in the right column. Instead of CPUs (1/1) in the left column, select CPUs (1/2) for the left column and CPUs (2/2) for the right column. F10 to save the changes and it's done.