0

I am very new to working with Linux so please be as elaborate as possible in your answers, thanks!

I am running WSL on Windows 10 using Ubuntu 18.04 LTS, and I am trying to run several (56) parallel processes in the background. From what I know, this can be simply done with the & syntax at the end of a command in shell. However, I found that, while my CPU utilization is 100%, it's temperature is very low ~45° Celsius. This is very unusual since fully loaded concurrent tasks, running on Python, bring up my CPU to at least 75° Celsius. The program I am running is compiled from fortran code, so it should always be doing calculations. Why this happening?

Another problem I am having is that, when I run these concurrent tasks, some of the processes get stuck in a suspended mode (checked through task manager), and I am not sure how to unsuspend them.

The script I am using to run these concurrent tasks is:

#!/bin/tcsh
    
@ ifile = $1
@ nrun  = $2
@ temp  = $3
@ irun  = 1

while ($irun <= $nrun)
        sudo nice -10 ~/Research/drift $ifile $irun $temp &
      # nice          ~/Research/drift $ifile $irun $temp &
        @ irun++
end

I've tried running with both nice commands (the commented and an uncommented one) to play around with the priority, but I was unable to get anywhere with it.

Any help or explanation would be greatly apreciated!

Task manager screen, showing the suspended processes : ?

UPDATE: It seems like by updating from WSL to WSL2 on windows 10 solved the problem of concurrent processes being stuck in a suspended mode. Hope this helps!

patrick7
  • 366
  • 1
  • 11
  • Do the tasks attempt to read from standard input or `/dev/tty`? That will not work when they are in the background, and the usual behavior is they get sent a stop signal, which would suspend them. – Nate Eldredge Mar 27 '22 at 21:54
  • @NateEldredge The drift task reads from a textfile in the same directory as the program "drift" – patrick7 Mar 27 '22 at 21:56

0 Answers0