Virtualization Font Family Operating System

Virtualization Font Family Operating System


QUESTION 1

  • What does the spin() function in our program do?

Path: p

Words:0

2 points

QUESTION 2

  • How can the operating system regain control of the CPU so that it can switch between processes?

uses application and non-cooperative

uses comment and content

uses cooperative and non-cooperative

uses application and non priviledge

2 points

QUESTION 3

  • In a situation where a number of relatively-short potential consumers of a resource get queued behind a heavyweight resource consumer is known as

a convoy effect

a content effect

a comment effect

a context effect

2 points

QUESTION 4

  • There are two processes: Process A and Process B. What are the situations of Process B when it is moved from Ready to Running and Process A when it has been moved from Running to Ready

Process B has descheduled and Process A has been blocked.

Process B has been scheduled and Process A has been Descheduled

Process A has been scheduled and Process B has been blocked

Process A has been scheduled and process B has been descheduled.

2 points

QUESTION 5

  • What C programming command can we use to check if it is installed on Kali Linx?

wherewas gcc make

wheremake gcc was

whereis gcc make

whereis make gcc

2 points

QUESTION 6

  • After a program compiled the cpu program what command was used to run the four processes?

./cpu “a”, ./cpu “b”, ./cpu “c”,; ./cpu “d”;

./cpu a;, ./cpu b,; ./cpu c; ./cpu d &

;/cpu a, ./cpu b &, ./cpu c,; ./cpu d

./cpu a & ./cpu b & ./cpu c & ./cpu d &

2 points

QUESTION 7

  • If time sharing allows a resource to be used for a little while by one entity, and then a little while by another. What is its natural counterpart and how does it uses its resources?

CPU, and the resource will process data until the running program is done then the OS will sit idle or forcefully take the process away

Mechanisms, where it shares low-level methods or protocols to implement a needed piece of programs using a context switch.

Space sharing , where a resource is divided into blocks among those who wish to use it. once a block is assigned to a file, it is not likely to be assigned to another file until the user deletes it.

All of the Above

2 points

QUESTION 8

  • Three jobs A, B, C, with run times of 5, 10, and 15 time units all arriving at the same time (0). What is the average turnaround time for jobs A, B, and C? Assumming FIFO is used

250/3

250/3

150/3

50/3

2 points

QUESTION 9

  • What switch is used between user program and the kernel when a priviledge access is requested?

a convoy switch

a content switch

a comment switch

a context switch

2 points

QUESTION 10

  • The OS uses low-level machinery called ———— and high-level ————- to implement virtualization well

mechanism and process identifier

concurrently and perfomance

mechanism and intelligence

process identifier and concurrently

2 points

QUESTION 11

  • What scheduler ia used with the introduction of time-shared machines?

Shortest Time First

Response Time

Round Robin

Shortest Time to Completion

2 points

QUESTION 12

  • There are two processes: Process A and Process B. What are the situations of Process B when it is moved from Ready to Running and Process A when it has been from Running to Ready

Process B has descheduled and Process A has been blocked.

Process B has been scheduled and Process A has been Descheduled

Process A has been scheduled and Process B has been blocked

Process A has been scheduled and process B has been descheduled.

2 points

QUESTION 13

  • There are two processes: Process A and Process B. What are the situations of Process B when it is moved from Ready to Running and Process A when it has been from Running to Ready

Process B has descheduled and Process A has been blocked.

Process B has been scheduled and Process A has been Descheduled

Process A has been scheduled and Process B has been blocked

Process A has been scheduled and process B has been descheduled.

2 points

QUESTION 14

  • When user mode wants to access kernel mode it invokes a system call, or ——-

algorithm

fetch

trap

high-level

2 points

QUESTION 15

  • A systrm call is made to keep running (create) the same copies of program, what procedure will be best used?

fork()

wait()

exec()

kill()

2 points

QUESTION 16

  • What C program command did we use to compile cpu.c

gcc cpu cpu.c -pthread

gcc-o cpu cpu.c

gcc -o cpu cpu.c -pthread

gcc cpu cpu.c

2 points

QUESTION 17

  • A new process has been created which leads to the creation of another process. What are the characteristics of this new process?

The creating process is called a parent, it has a process identifier, and it will execute after the created process called a child has executed.

The created process uses create routine called a parent, the process identifier is not needed, and it will execute first. The mechanic process is called a child.

The created process is called a parent, it has a process identifier, and it will execute first. The creating process is called a child, it has a process identifier but cannot execute.

The creating process is called a parent, it has a process identifier, and it will execute first. The created process is called a child, it has a process identifier but cannot execute.

2 points

QUESTION 18

  • Where does a program stores its data structures?

Path: p

Words:0

2 points

QUESTION 19

  • What is Virtualization of the CPU

Path: p

Words:0

2 points

QUESTION 20

  • What scheduler is considered the most basic of all the algorithms?

FIFO

SJF

STCF

RR

2 points

QUESTION 21

  • After a switch has been made, the results are returned back to the calling user application and this is called

return-from-trap

return-from-algorithm

return-from-fetch

return-from-low-level

2 points

QUESTION 22

  • A new process has been created which leads to the creation of another process. What are the characteristics of this new process?

The creating process is called a parent, it has a process identifier, and it will execute after the created process called a child has executed.

The created process uses create routine called a parent, the process identifier is not needed, and it will execute first. The mechanic process is called a child.

The created process is called a parent, it has a process identifier, and it will execute first. The creating process is called a child, it has a process identifier but cannot execute.

The creating process is called a parent, it has a process identifier, and it will execute first. The created process is called a child, it has a process identifier but cannot execute.

2 points

QUESTION 23

  • What function will repeatedly checks the time and returns once it has run for a second?

Fetch()

Spin()

wait()

exec()

2 points

QUESTION 24

  • Tresponse =

Tcompletion – Tfirstrun

Tfirstrun – Tarrival

Tfirstrun – Tturnaround

Tturnaround – Tcompletion

2 points

QUESTION 25

  • What are the two challenges faced by an OS in building such virtualization machinery. .

performance and convoy effects

mid-level and low-level

time sharing and space sharing

performance and control

2 points

QUESTION 26

  • An operating system must include some methods to ———, ——–, ———, new APIs

create. edit, and delete

create, destroy, and wait

fetch, decode, and run

fetch, create, and destroy

2 points

QUESTION 27

  • When does a trap table initializes?

after the OS closes

during an application use

after using an application

during the OS boot

2 points

QUESTION 28

  • If time sharing allows a resource to be used for a little while by one entity, and then a little while by another. What is its natural counterpart and how does it uses its resources?

CPU, and the resource will process data until the running program is done then the OS will sit idle or forcefully take the process away

Mechanisms, where it shares low-level methods or protocols to implement a needed piece of programs using a context switch.

Space sharing , where a resource is divided into blocks among those who wish to use it. once a block is assigned to a file, it is not likely to be assigned to another file until the user deletes it.

All of the Above

2 points

QUESTION 29

  • Tturnaround =

Tarrival – Tperformance

Tcompletion – Tcontrol

Tperformance – Tcontrol

Tcompletion – Tarrival

2 points

QUESTION 30

  • When the machine boots up, it does so in what mode?

application mode

privileged

least privileged

spacing mode

2 points

QUESTION 31

  • The three system calls used to create a process in Unix are ————-

fork(), wait(), and exec()

create(), destroy(), and exec()

fork(), wait() and create()

create(), exec(), and destroy()

2 points

QUESTION 32

  • Draw a valid conclusion on the following codes:

prompt> ./mem 1 & ./mem 2

[1] 24113

[2] 24114

(24113) memory, address of p: 00200000

(24114) memory address of p: 00200000

OS is virtualizing memory

CPU is executing memory

Memory is virtualing CPU

No valid conclusion can be drwan from above

2 points

QUESTION 33

  • Define the following terms

a. Fetch

b. Decode

c. Execute

d. PID

e. distributed operating system

f. virtualization

Path: p

Words:0

2 points

QUESTION 34

  • What information is found in the trap table?

codes used by hardware to know which particular trap to use

codes used by software to know which particular trap to use

codes used by hardware to trace which particular fetch()

codes used by software to trace which particular fetch()

2 points

QUESTION 35

  • A systrm call is made to keep running (create) the same copies of program, what procedure will be best used?

fork()

wait()

exec()

kill()

2 points

QUESTION 36

  • What scheduler uses preemptive?

FIFO

SJF

STCF

RR

2 points

QUESTION 37

  • There are currently two programs: Program A is running and program B is blocked. What is the name of the running program?

algorithms

virtualization

convoy effects

process

2 points

QUESTION 38

  • A new process has been created which leads to the creation of another process. What are the characteristics of this new process?

The creating process is called a parent, it has a process identifier, and it will execute after the created process called a child has executed.

The created process uses create routine called a parent, the process identifier is not needed, and it will execute first. The mechanic process is called a child.

The created process is called a parent, it has a process identifier, and it will execute first. The creating process is called a child, it has a process identifier but cannot execute.

The creating process is called a parent, it has a process identifier, and it will execute first. The created process is called a child, it has a process identifier but cannot execute.

2 points

QUESTION 39

  • There are currently two programs: Program A is running and program B is blocked. What is the name of the running program?

process

virtualization

convoy effects

algorithms

2 points

QUESTION 40

  • What are the three open ?le descriptors in each process by default in Unix Systems

standard input, output, and error;

fetch, wait, and exec

create, edit, and delete

standard fetch, output, and input

2 points

QUESTION 41

  • The hardware assists the OS by providing different modes of execution, which one uses the application mode?

user mode

kernel mode

fetch mode

process mode

2 points

QUESTION 42

  • The setback of virtualization is “—————” as each will run more slowly if the CPU(s) must be shared.

create

destroy

performance

decoding

2 points

QUESTION 43

  • If time sharing allows a resource to be used for a little while by one entity, and then a little while by another. What is its natural counterpart and how does it uses its resources?

CPU, and the resource will process data until the running program is done then the OS will sit idle or forcefully take the process away

Mechanisms, where it shares low-level methods or protocols to implement a needed piece of programs using a context switch.

Space sharing , where a resource is divided into blocks among those who wish to use it. once a block is assigned to a ?le, it is not likely to be assigned to another file until the user deletes it.

All of the Above

2 points

QUESTION 44

  • Discuss how the operating system virtualize memory in Figure 2.3

Path: p

Words:0

2 points

QUESTION 45

  • What scheduler will not run jobs to completion, but runs a job for a time slice?

FIFO

SJF

STCF

RR

2 points

QUESTION 46

  • Using sjf calculate the average turnaround time for the following processes A,B,C, 50, 5, 5 all arriving at the same time

25

35

45

55

2 points

QUESTION 47

  • There are currently two programs: Program A is running and program B is blocked. What is the name of the running program?

process

virtualization

convoy effects

algorithms

2 points

QUESTION 48

  • Timer interrupts are a useful mechanisms for the OS why?

used to hand control to the OS

used to execute the OS

makes mechanisms work well for the OS

makes response time effective

2 points

QUESTION 49

  • A systrm call is made to keep running (create) the same copies of program, what procedure will be best used?

fork()

wait()

exec()

kill()

2 points

QUESTION 50

  • A Unix programmer started a process, what three commands are needed?

fetches an instruction from memory, executes it and encode it

fetches an instruction from memory, decodes it and jumps to a function

executes an instruction from memory, decodes it and fetches it

executes an instruction from memory, decodes it and fetches it

+