0% found this document useful (0 votes)
6 views2 pages

CSC 401 MidSem Spring 2023-2024 Operating Systems

The document outlines the Mid Semester Examination for the Operating Systems course at the Indian Institute of Information Technology Kalyani, detailing the structure and instructions for the exam. It includes various questions related to computer systems, programming tasks in C, and concepts such as DMA, MBR, and process states. The exam consists of multiple sections with specific marks allocated for each question, emphasizing the need for original answers and neat presentation.

Uploaded by

sayanshit171
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)
6 views2 pages

CSC 401 MidSem Spring 2023-2024 Operating Systems

The document outlines the Mid Semester Examination for the Operating Systems course at the Indian Institute of Information Technology Kalyani, detailing the structure and instructions for the exam. It includes various questions related to computer systems, programming tasks in C, and concepts such as DMA, MBR, and process states. The exam consists of multiple sections with specific marks allocated for each question, emphasizing the need for original answers and neat presentation.

Uploaded by

sayanshit171
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/ 2

B.Tech.

/CSE/4th Sem-M/2024/CSC401
Indian Institute of Information Technology Kalyani
Mid Semester Examination, Spring 2023 - 2024
Subject: Operating Systems Time: 90 Mins.
Paper Code: CSC401 Full Marks: 30

Instructions:
[1]. Answer all questions and each answer should be in your own words, otherwise, you will be awarded
zero mark. [2] All parts of a question should be answered consecutively. [3]. Answer the questions to the
points. [4]. Answer script should be neat and clean. [5]. Do not write anything on the question paper.
[6]. Number of pages in the question paper: 02.

Q1. Answer the following questions. [2 × 5 = 10]

(a) How does DMA reduce CPU Overhead in data transfer operations involving peripherals like disk
drives and network interfaces?

(b) Write two purposes for which Memory Buffer Register (MBR) is used in a computer system.

(c) Why Program Status Word (PSW) is needed in a computer system?

(d) Write two significant differences between a multi-programming system and a multi-tasking system.

(e) How many times “IIIT Kalyani” will be printed by all the child processes?

int main()
{
if(fork()&& fork())
fork();
printf(“IIIT Kalyani”);
return 0;
}

Q2. Answer the following questions. [3 × 4 = 12]

(a) Write a C program that creates a n number of child processes using the fork() system call. Each
child process should print its process id and its parent’s id. The parent process should wait for
all child processes to terminate before exiting. The number of child processes to create should be
specified as a command-line argument.

(b) Write a C program (to copy a file) to simulate the following command copy oldfile newfile
typed by an user at the terminal. Here oldfile is the name of the existing file whose contents to
be copied to the file newfile.

(c) Write a C program that opens a file named abc.txt, and writes “IIIT Kalyani” to it using the
system call write(). Use the system call lseek() to set the file offset to the beginning of the file
and reads the content using the system call read().

(d) Write a C program that display all the file from the current working directory.

1
Q3. State the reasons for the following situations. [2 × 2 = 4]

(a) When a process moves from a Ready/Suspend state to a Ready state?

(b) When a process moves from a Running state to a Ready/Suspend state?

Q4. Answer the following questions. [2 × 2 = 4]

(a) Create a shared memory of 1024 bytes for private communication between two processes, and attached
it with the process created it.

(b) Detached the created shared memory from the process space, and it from the system.

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