0% found this document useful (0 votes)
4 views10 pages

Operating System

This document outlines the structure and content of the Sessional Test for the Operating System course at Chitkara University for the academic year 2022-2023. It includes instructions for different sections of the test, types of questions, and marks distribution. The test covers various topics related to operating systems, including process management, memory allocation, and CPU scheduling algorithms.

Uploaded by

anurag1101.be23
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
4 views10 pages

Operating System

This document outlines the structure and content of the Sessional Test for the Operating System course at Chitkara University for the academic year 2022-2023. It includes instructions for different sections of the test, types of questions, and marks distribution. The test covers various topics related to operating systems, including process management, memory allocation, and CPU scheduling algorithms.

Uploaded by

anurag1101.be23
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 10

CHITKARA

UNIVERSITY
1
HIMACHAL PRADESH
NAAC ACCREDIFD

2022-2023

Sessional Test 1- April, 2023


Semester Even
ID No: [Total No. of Pages: 03|
Title of the Course: Operating System Time: 90 minutes
Course Code: CS115 Max. Marks: 40

Instructions:
For Section A
There are 5 multiple choice Questions of 1 mark each. All are compulsory.
For Section B
There are 6 Questions of 2 marks each. There is a choice to attempt 5 questions out of 6.
For Section C
There are 4 Questions of 5 marks each. There is a choice to attempt 3 questions out of 4
For Section D
ofT
There are 2 Questions of 10 marks each. There is a choice to attempt 1 question out

Section-A

(Question 1 is Compulsory; each part carries 1 mark)

Q 1. Choose the correct answer:

a) If any user wantsto run multiple processes on the system, then OS will arrange these processes in
such a way that CPU will always be busy. This will increase
(i) memory access time (ii) disk access time
(ii) CPUUtilization (iv) Turnaround time

b) Ascheduler which selects processes from secondary storage device is called


() Short term scheduler (ii) Long term scheduler
(ii) Medium term scheduler (iv) Process scheduler

c) When process P1 is created by user1, the state of P1 will be


(i) Running (ii) New

(ii) Ready (iv) Waiting

1
CHITKARA
UNIVERSITY
1
HIMACHAL PRADESH 2022-2023
NAAC ACCREDITFD

the
process P2. Here
shared with another
a database file
d) Suppose a process P1 is making changes to
database file is a:
Entry section
Critical section (i) Remainder section
(i)
Exit section (iv)
(ii)
per unit time is known as.
e) The number of processes completed Throughput
Output
()
(i)
(i) Efficiency (iv) Capacity

Section-B

question carries 02 marks)


(Attempt any 5 questions, each
of Unix.
any two process control system callspriority
Q2. Define the functions of system call. List process P2 with high arrives. Describe the
executing a process P1 and a new
Q3. Suppose the CPUis context switch between these processes.
actions taken by a kernel to
process.
Q4. Compare and contrast thread and conditions which asolution
Two processes want to run their critical section code successfully. Give the
Q5. processes must satisfy.
to the critical section problem of these differences between
tasks T1, T2, T3 and T4 are required to be executed by the CPU. List the
Q6. Four these tasks.
concurrent and parallel execution of
symmetricand asymmetric multiprocessing.
Q7. Describe the difference between

Section-C

marks, subparts (if any) carry equalweightage)


(Attempt any 3 questions, each question carries 5
discuss a suitable
designed using various approaches. Sketch and
Q8. Operating systems structure can be the reason in selecting your choice.
structure of the operating system and mention
on it. AlsO
to exchange data and information". Comment
09. "Cooperating processes require IPC mechanism
model.
discuss the message passing the process
O10.Define a semaphore. Demonstrate the working of P and V semaphores used in
synchronization.
threading models provide better performance than
011.Can a multithreaded solution using many to many
diagrams.
many to one threading models? Explain your answer using suitable

2
CHITKARAal
UNIVERSITY
HIMACHAL PRADESH

2022-2023
Section-D
(Attempt any one question, each question carries 10 marks, subparts (if ony) corry
equal weight age)
Q12.(i) The functions provided by the operating system can be
three categories by giving example of each category.
grouped into a few categories. Explain any
()Consider asystem consisting of the processes listed below in
table, draw a chart illustrating their
execution using shortest job first scheduling algorithm. Calculate the completion time, turnaround
time and waiting time of each process. Also calculate
time.
average waiting time and average turnaround

Process Arrival Burst


Name
Completion Turn Waiting Average Turn Average
Time (ms) Time Time Around Time Around Time Waiting
(ms) Time Time
P1
3
P2 2 6
P3 4
P4 6 5

8 2

O13. (i) Different CPUscheduling algorithms have


different properties and the choice of a particular
may favour one class of processes over
another. DiscuSs any three criteria which vou will algorithm
select for
comparing different CPU scheduling algorithms.
(ii) For the processes listed below in table, draw a
chart
scheduling algorithm. Calculate the completion time,illustrating their execution using Round Robin
turnaround
process. Also calculate average waiting time and average tÉme and waiting time of each
turnaround time
Process Arrival Burst Completion Turn
Name Time Time Time Around
Waiting Average Average
Time Turn
(ms) (ms) Time Waiting
Around Time
Time
P1 6

1 4
P2

2 2
P3
4 1
P4
2022-2025

CH
2023
Sessional Test l -May,
TY

EVEN SEMESTER
03)
(Total No. of Pages:
Time: M mínutes
ID No Max Marks: 40

Title of the Course: Operating System


Course Code:CS115
will be correct.
ostructions:
distinct ootions out of which onty one dhoice
Section A
having five parts.Each part is having four
inere is one questionmarking for incorrect answers.
There is no negative
ction B questions out of 6.
each There is a choice to attempt 5
There are 6 Questions of 2 marks
For Section C There is a choice to attermpt 3 questions
out of 4.
There are 4 Questions of 5 marks each.
ForSection D
choice to atternpt 1 question out of Z.
There are 2Questions of 10 marks each. There is a

Section-A

mork)
(AllQuestions are Compulsory, Eoch question carries 01

deadlock occurrence?
a) Which one of the following is a vísual way to determine the
(i) Starvation graph
Resource allocation graph
(io) Inversion graph (iv) Process graph

and the relocation register contains a value 14000. What will be


b) Let the virtual address generated by a user program is 346
the actual physical memory address?
64341
(1) 143460
(iv) 14346
13654

on secondary storage and is the smallest


Which of the following is a named collection of related information that is recorded
allotment of logical secondary storage?
File
Directory
(iü) Disk (iv) Tape

d) The operating systern implernent system calis for processes to request access to file contents
Read') and writel) () Open() and close()
Open() and Write() (iv) Read () and Truncate{)

1
CHTESRSa
Soresserl iet

Tata f
Tme nimes

E4342
434

Fie
Tace

ezprocesses to recuest acres o fie contents

Cpent and cose)


Read )and Truncate)
CHITKARA
UNIVERSTY
1 2022-2023
Sosslonal Test I|
-May, 2023
EVENSEMESTER

ID No:,..
(Total No. of Pages: 03)
Title of theCourse: Operating System
Time: 90 minutes
CourseCode: CSI15 Max. Marks: 40

Instructions;
For Section A
parts. Each part is having four distinct options out of which only one choice will be correct.
There is one question having fiveincorrect answers.
for
There is no negative marking
For SectionB attempt 5 questions out of6
There are 6 Questions of 2 marks each. There is a cnorce t0
For Section C to attempt 3 questions out of 4.
There are 4Questions of 5 marks each. There 1s a cnolce
For Section D Choice to attempt 1 question out of 2.
There are 2 Questions of 10marks each. There is a

Section-A

(AllQuestions are Compulsory, Each question carries 01 mark)

1
determine the deadlock occurrence?
a) Which one of the following is a visual way to
(i) Resource allocationgraph (i) Starvation graph
(iv) Process graph
(ii) Inversion graph

the relocation register contains a value 14000. What will be


b) Let the virtual address generated by a user program is 346 and
the actual physical memory address?
(ii) 64341
143460
(iv) 14346
(ii) 13654

secondary storage and is the smallest


c) Which of the following is a named collection of related information that is recorded on
allotment of logical secondary storage?
(ii) File
Directory
(i) Disk (iv) Tape

d) The operating system implement . . . . system calls for processes to request access to file contents.
(iü) Open() and close()
(i) Read() andWrite()
(i) Open() and Write() (iv) Read () and Truncate()

1
to select
a. memory
e) The strategies like the first fit, best fit and worst fit are used queue to put in
Process from a available holes
Process from a queue to put in storage (ii) from asetof
Free hole
Processor to run the next process (iv)

Section-B

question carries 02 marks)


(Attempt any 5 questions. eoch
Distinguish between logical and
virtual and physical address space.
2 Execution time address binding scheme results in different
physical addresses generated by this scheme. process and page tables.
3 Suppose a process P1 is making use of paging. Mention the purpose of paging this
4 Explain the disadvantages of single contiguous memory allocation.
5 List the advantages of contiguous disk space allocation method for files.
in deadlock state. Under what situation these processes
6. ATew processes Competing for the resources mav be in stavation or
are said to be in starvation or in deadlock?
7. Differentiate between a file and a directory.
Section-C

(Attempt any 3 questions, each question carries 5 marks, subparts (if any) carry equal weightage)
The file information stored in a computer system can be accessed and read into computer memory in several ways. Explain
briefly the different access mechanism methods to read the files of the computer system.
9
Compare the memory organization schemes of contiguous memory allocation and non-contiguous menmory allocation scheme
with respect to the following issues:
a. External fragmentation
b. Internal fragmentation
C. Simplicity
d. Execution speed
e. Types

10. Afile's attributes vary from one operating system to another. Describe the typical attributes of the files briefly
11 Suppose vouwant maximum utilization of CPU and for this you
need to perform swapping. Explain the technigue of standard
Swapning of two processes using suitable diagram. Let's assume that a user
ctandard hard disk with a transfer rate of 50 MB per second. Compute procesS 100 MB in siize and the backing store is a
is
the actual transfer of the 100-MB process to or from
main memory.

Section-D
(Attempt anyone question, each question carries 10 marks, subparts (if any)carry
equal weightage)
12 Consider a system having n resources and m no. of active
prOcesses. Discuss the necessary conditions for the
deadlock in this system. occurrence of a
let a svstem with five processes PO through P4
and three resource types A, B, and C.
resource type B has five instances, and resource type Chas Resource type A has ten instances
seven instances. Suppose that, at time T0, the
the system has been taken: following snapshot of

2
Process Allocation Maximum
A B C A B C

PO 1 0 7 3

P1 2 3 2

P2 3 2 9 0 2

P3 2 1 1 2 2 2

P4 2 4 3 3

Apply Banker's algorithm for deadlock avoidance of the above system.

13. State
XYZ
and define virtual memory with respect to memory management. Suppose you are given the role of hardware engineer in
semiconductor company, write the steps which you will foliow in handling a page fault using demand paging technique.
Let the probability of page fault is 0.2,.page fault service time is 8 milliseconds and a memory access time is 200 nanoseconds
for ademand-paged memory. Compute the effective acces time for this memory in nanoseconds?
DO NOT WRITE ANYTHING ON QUESTION PAPER EXCEPT ID NO.

ID No... Total No. of Pages:02


END TERM EXAMINATION
July, 2023
CS115- Operating System
Department: CSOET Batch: 2022
Time allowed: 03 Hours Max. Marks: 60
General Instructions:

Follow the instructions given in each section.


Make sure that you attempt the questions in order.
Assume necessary data if required

SECTION-A(5x1 mark=05 marks)


(Question I() to l() has four choices, out of which only one is correct, no negative marking for wrong
answer)
QI
i) The value of segment base in a segment table is 4300 and the segment limit is 500. A reference to byte 50 of
this segment is mapped onto a location given as:
a) 4800 b 4300
c) 4350 d) 4250
The basic unit of CPUutilization is named as:
a) Process b) Semaphore
c) Scheduler d) Thread
iii) Consider a non preemptive system in which a process arrives at time t =io ms and completes at tine t = 100
ms. The process starts its execution at time t=32 ms. The waiting time (in ms) of the process is:
a) b) 68
c) 22 d) 32
iv) Which of the following provides the mechanism for on-line storage and access to both the data and programs
in the operating system?
a) Secondary storage mechanism b) File system
c) Memory management d) Protection mechanism
A .consists of malicious or fraudulent repeat of avalid datatransmission.
a) Masquerading b) Denialof service
c) Man in the middle attack d) Replay attack

SECTION-B(5x2 marks=10 marks)


(Atempt any 5 questions, each question carries 02 marks)

Q2 In some systems it is possible to map part of afile into memory. How is this partial mapping implemented?
Q3 State the mechanism and policy of operating system protection.
Q4 Define external fragmentation. Mention the reason for occurrence of external fragmentation.
Q5 List the advantages of contiguous allocation of disk space for files.
Q6 Draw a neat diagram of the structure of an operating system and explain briefly.
Q7
1Page
Most of the operating systems provide delete and truncate file operations. Is there any dilerence amono/
between these operations? Justify your answer.

CSI15, AY 2022-23
DO NOT WRITE ANYTHING ON QUESTION PAPER EXCEPT ID NO.
SECTION-C (5x5 marks-25 marks)
(Attempr any Squestions , each question carries 0S marks)
QS Ruce conditions are possible in many computer systems. Consider a banking system that maintains an
account balance with two funetions: deposit (amoun) and withdraw (amount). These two functions are
passed the amount that is to be deposited or withdrawn from the bank account balance. Assume that a
husband and wife share a bank account. Concurrently, the husband calls the withdraw ( ) function and the
wife calls deposit ( ). Deseribe how a race condition is possible and a software solution to prevent the race
condition from occurring.
Q9 Distinguish between the following terminologies associated with the operating system and briefly discuss
them:

a) Multiprogramming.
b) Multitasking
c) Multiprocessing system
QlO Using a neat diagram discuss the steps to handle a page fault in demand paging.
QI Summarize the deadlock prevention and deadlock avoidance methods for handling the deadlock.
Q12 Explain the following types of security threats:
a) Trojan horse
b) Worms
c) Denial of service
Q3 Aprocess goes through different states throughout its life cycle. Diseuss the various states of the process
using a suitable diagram.
SECTION-D (2x10 marks=20 marks)
(Atempt any 2 questions, each question carries 10 marks)

Q14 a) Explain the Round Robin scheduling algorithm by using asuitable example and Gantt chart.
b) Consider the following four processes with the length of CPUburst given in milliseconds:
Process Arrival Time Burst Time

Pl
P2 4

P3 2

P4 5

Draw Gantt chart using pre-emptive shortest job first(SJF) scheduling algorithmand find out the completion
time, turnmaround time, waiting time and the average waiting time.
Q15 Consider adisk queue with requests for I/O to blocks on following cylinders:
1, 36, 16, 34, 9, 12

Suppose that the disk drive has 40 cylinders numbered from 0 to 39 and the current head position is at
cylinder no. |1. What is the total distance (in cylinders) that a disk arm moves to satisfy all the pending
requests for each of the following disk scheduling algorithms? Use suitable diagrams to justify your answer.
a. FCFS
b. SSTF

Q16 The operating system services provide functions that are either helpful to the user or ensure the efficient
2Page
operation of the system itself. Discuss any five operating system services that are helpful to user and any two N
services that ensure the efficient operation of system.

CST15, AY 2022-23

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy