1

I have access to the Linux account (named jupyter), but when running certain commands, it cannot utilize all of the available CPUs.  Once I switch to another user I can use all CPUs.

I use this command for tests:

for i in $(seq $(getconf _NPROCESSORS_ONLN)); do yes > /dev/null & done

I'm checking CPU load with htop.

When I run this command on user jupyter, I get a total of 98.6% CPU usage (i.e., an average of 12.3% on each of eight CPUs).

Tasks: 45, 130 thr; 9 running
Load average: 1.67 0.94 0.38
Uptime: 00:05:38
         ︙
Mem[... 541M/31.4G]

htop output

      Note: text has been manually transcribed from images.

When I run this command on user test1, I get 100.0% CPU usage on each CPU.

Tasks: 49, 130 thr; 9 running
Load average: 2.29 0.65 0.24
Uptime: 00:04:27
         ︙
Mem[... 552M/31.4G]

[See image of text.]

User jupyter is default user for this notebook.

Any ideas?

Marian
  • 11
  • 2
  • 1
    Linux has some methods for limiting a users Cpu usage: https://superuser.com/questions/1112614/how-to-limit-an-entire-user-to-less-than-10-of-cpu-not-just-process – Mokubai Apr 26 '21 at 08:55
  • /etc/security/limits.conf is empty (all lines commented out with #), cpulimit not installed, /etc/cgconfig.conf does not exist. – Marian Apr 26 '21 at 09:13
  • As it was jupyter notebook limitation was set in /lib/systemd/system/jupyter.service :-) – Marian Apr 27 '21 at 19:27

1 Answers1

0

Adding this for visibility.

The limit is set in

/lib/systemd/system/jupyter.service

All credit goes to Marian

telometto
  • 239
  • 1
  • 9