BİLKENT UNIVERSITY

DEPARTMENT OF COMPUTER TECHNOLOGY AND PROGRAMMING

CTP203 Operating Systems

Spring 2000

Mid Term 2

Name/Surname:

Instructor : Can Uğur Ayfer Assistant : Ece Yargı

Date : 05 May 2000 13:40

Please read the questions carefully. Attempt ALL the questions. There are 9 questions on two pages

Dictionary :

faulty : Hatalı- hata içeren
circuit : elektronik devre
allocate
: ayırmak-tahsis etmek
concurrently : birlikte-aynı zamanda
invalid : geçersiz
equipped :
donatılmış

1

What does DNS (Domain Name Services) mean in Internet terminology? ( 10 pts)

DNS is a software TCP/IP service which resolves IP addresses for given symbolic Internet host names and vice-versa. For example, the DNS service can convert the symbolic address of www.bilkent.edu.tr to 139.179.10.8. The reverse is also true for DNS; if you submit the IP address, DNS will resolve and find the symbolic host name.

2

What does CRC (Cyclic Redundancy Check) mean in digital data transfer terminology? ( 10 pts)

CRC is a technique used to detect any errors that can occur while transferring data from one point to other (or from one device to other). This technique arithmetically adds the bytes of data streams (ignoring any carries) and append this CRC byte (or bytes) to the data stream. The receiving side performs the same operation to check whether the received data stream had any of bits lost/changed during transmission.

3

Which of the following are invalid IP numbers in TCP/IP networking? WHY? ( 10 pts)

  1. 225.226.227.228 VALID
  2. 253.254.255.256 INVALID, because the last octet is greater than 255
  3. 1.1.1.1 VALID
  4. 225.225.225.225 VALID

4

Which of the following data bytes contain faulty data in a memory equipped with EVEN PARITY error checking circuit? WHY? ( 10 pts)

  1. 1 1 1 0 0 0 1 0 FAULTY, because there is no parity bit, or a data bit
  2. is lost during transmission.

  3. 1 1 1 1 0 0 1 0 0 FAULTY, because there are odd number of 1's
  4. 0 0 0 0 1 1 0 1 1 CORRECT, because there are even number of 1's
  5. 1 1 1 1 1 1 1 1 1 FAULTY, because there are odd number of 1's.
  6. 0 0 0 0 0 0 0 0 0 CORRECT, because there are even number of 1's

 

 

5

What does "kernel" mean in operating systems terminology? (10 pts)

"Kernel" is the collection of operating system modules that must be loaded into the memory during booting and stay in the memory all the time. Kernel contains operating system modules that are needed all the time.

6

Given the following virtual memory setup, what is the maximum size that the operating system can allocate to running processes? (10 pts)

  • Physical RAM size: 32 Mbytes
  • Operating system size : 16 Mbytes ( 6 Mbytes kernel + 10 Mbytes other modules)
  • Swap file size : 100 Mbytes

Show your calculations CLEARLY.

Since the kernel is 6 Mbytes, 26 MBytes of physical memory will be available for running/active processes ( 32 - 6 = 26 ). An additional 100 MBytes of memory can be allocated as virtual memory. Hence the total memory that can be allocated to running/active processes is 126 MBytes.

7

Considering the parameters given for question 6 (the question above), what is the max number of processes that can run concurrently on this computer? Explain your answer clearly. (10 pts)

The max number of processes that can run concurrently depends on the total amount of memory these processes require. The number of processes alone is NOT a limiting factor; it is the total amount of memory needed which limits creation of new processes.

8

Suppose you have a disk of max physical capacity of 1024 Mbytes. Which of the following are false and WHY? (15 pts)

  1. The max number of files that the operating system can put on this disk is 1024 x 4.
  2. The max size for a SINGLE file that the operating system can put on this disk is exactly 1024 x 1024 x 1024 bytes.
  3. The max size for a file is not limited because the operating system can use virtual memory techniques to allocate space for files(s) which require more space than there is available.

  1. False! This was a trick question. The "x 4" has no meaning. The max number of files that can put on a disk is not related to disk capacity and has nothing to with multiplication factor of 4.
  2. False! The operating system must reserve disk space for the FAT and directory entries on the disk. Therefore the max size of even a single file must be smaller than the physical disk capacity.
  3. False and also nonsense! Virtual memory technique uses disk space to store memory blocks temporarily so that rarely used memory pages can be better utilized by processes who need memory space. Using disk space to store disk space does not make sense!

 

 

9

Explain how it is possible to “undelete” files (recover deleted files) on disks managed by the MS-DOS/Windows operating systems. Please note that the question IS NOT “How do you undelete files?”! (15 pts)

When a file is deleted, MS-DOS and Windows replaces only the first character of file names in the directory entries that belong to that file by a special character which means "this file has been deleted". The operating system does not clear the block numbers that specify which disk blocks are occupied by that file. This saves time. So, if you can somehow replace the "this file has been deleted" mark with a valid file name character, the file is recovered provided that the disk blocks have not been used to store another file and the deleted directory entry is not used for other file(s). Note that when a file is to be undeleted, the blocks that the file occupies must be marked as "used" in the Fle Allocation Table too.