OS: CentOS 7.9
I want to simulate/create 1 process for test purposes, such that top
reports it consuming more than %100 CPU. Something looks like below in ps output;
USER PID %CPU COMMAND
user.one 111245 1500 command
There are stress and stress-ng commands but they only allow 100
-l P, --cpu-load P load CPU by P %%, 0=sleep, 100=full load (see -c)
I also tried to run the stress command with mpirun with oversubscribed option but no luck.
-oversubscribe, --oversubscribe
Nodes are allowed to be oversubscribed, even on a managed system, and overloading of processing elements.
Thank you in advance!
top
is inconsistent in the way it aggregates CPU usage in different places, and in how threads are treated as processes. It averages stats over several seconds, which introduces anomalies. It does not even differentiate CPUs from cores.stress
lives in the real world -- it blitzes one core until it consumes every available cycle.