Score:0

How to limit CPU utilization for a process in ubuntu vm

tc flag

I am using ubuntu 20.04 VM for a course. For an assignment, I need to run a command that creates some thread and two processes happen simultaneously. However as soon I run the command ubuntu slows down and the CPU utilization goes to 200% for that process. I allotted 8GB/16GB RAM to oracle VM and 6/12 CPUs (Oracle forbids to allocate beyond 6 CPUs).

A screenshot of situation is attached:enter image description here

Is there some way to prevent this to happening?? Maybe some alternative that takes less CPU but more time? Also will this issue occur in WSL2??

PS: I am new to ubuntu and don't know the inner working at all. My friends and the Teaching assistants are not familiar with VM. I cannot dual boot ubuntu, last time it gave serious issues.

David avatar
cn flag
last time it gave serious issues. Explain please.
tc flag
The hard disk was not partitioning properly and the experience while using dual booted ubuntu was very bad, the graphics were not nice, it used to hang a lot and discharge at 3x and finally it vanished after a windows update
ChanganAuto avatar
us flag
Clearly you need to understand (1) hardware and "drivers" requirements, namely graphics card/chip, and (2) how to manage a dual-boot, something that's easier then ever with UEFI and OSes installed in the proper UEFI mode.
David avatar
cn flag
That makes no sense the partitioning of the hard drive in no way affects the graphics. Any way it sounds like it was poorly installed not the Os s fault.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.