Sie sind auf Seite 1von 4

MC415 OPERATING SYSTEM.

REVIEW QUIESTIONS.

CHAPTER ONE (1) REVIEW QUESTIONS.

1. What are the four (4) components of a Computer System?


 Hardware – provides basic computing resources
i. CPU, memory, I/O devices
 Operating system
i. Controls and coordinates use of hardware among various applications and users
 Application programs – define the ways in which the system resources are used to solve the computing problems of the
users
i. Word processors, compilers, web browsers, database systems, video games
 Users
i. People, machines, other computers
2. What are the three (3) goals of an Operating system?
 Execute user programs and make solving user problems easier
 Make the computer system convenient to use
 Use the computer hardware in an efficient manner
3. What are the four (4) components of an operating systems and describe their functions?
 User Interface - refers to the part of an operating system, program, or device that allows a user to enter and receive
information.
 File management system - File management is defined as the process of manipulating files in computer system, its
management includes the process of creating, modifying and deleting the files.
 Input/Output - Disk management functions such as free space management, storage allocation, fragmentation removal,
head scheduling
 Memory Management system – map process to memory location and allocate memory space as require or requested.
 Kernel – one program running at all time in the computer.
4. Describe the two stages of transferring data from a storage device to RAM.
 Device controller moves data to/from device to/from its own buffer
 CPU moves data from/to main memory to/from local buffers
5. What is an interrupt and what is its purpose?
 An interrupt is a signal that a device uses to get an attention of the CPU and is usually generated when I/O is required.
 Purposes is to prompts the operating system to stop working on one process and start working on another.
6. Describe the purpose of the two (2) modes of OS operation.
 User mode – use for executing user processes.
 Kernel mode – use to give processes direct access to the hardware.
7. What is caching and where is it used?
 It is used to copying information into faster storage system.
 It is viewed/used in the main memory as secondary storage.
8. List two (2) activities for which the OS is responsible for in Process Management.
 Creating and deleting both user and system processes.
 Suspending and resuming processes.
9. List two (2) activities for which the OS is responsible for in memory Management.
 Keeping track of which parts of memory are currently being used and by whom.
 Deciding which processes and data to move into and out of memory.
10. List five (5) different computing environments Computer system can be divided into.
 Traditional,
 Mobile,
 Distributed,
 Client server
 Peer-to-peer
 Virtualization

CHAPTER TWO (2) REVIEW QUESTIONS.

1. List 6 main OS services useful for the user.


 User interface - Almost all operating systems have a user interface (UI).
This interface can take several forms. One is a command-line interface (CLI), which uses text commands and a method
for entering them (say, a keyboard for typing in commands in a specific format with specific options). Another is a batch
interface, in which commands and directives to control those commands are entered into files, and those files are
executed. Most commonly, a graphical user interface (GUI) is used. Here, the interface is a window system with a
pointing device to direct I/O, choose from menus, and make selections and a keyboard to enter text. Some systems
provide two or all three of these variations.
 Program execution - The system must be able to load a program into memory and to run that program. The program
must be able to end its execution, either normally or abnormally (indicating error).
 I/O operation - A running program may require I/O, which may involve a file or an I/O device. For specific devices,
special functions may be desired (such as recording to a CD or DVD drive or blanking a display screen). For efficiency and
protection, users usually cannot control I/O devices directly. Therefore, the operating system must provide a means to
do I/O
 File system manipulation - The file system is of particular interest. Obviously, programs need to read and write files and
directories. They also need to create and delete them by name, search for a given file, and list file information. Finally,
some operating systems include permissions management to allow or deny access to files or directories based on file
ownership

Jkeako 12245 summary


MC415 OPERATING SYSTEM.
REVIEW QUIESTIONS.

 Communication - There are many circumstances in which one process needs to exchange information with another
process. Such communication may occur between processes that are executing on the same computer or between
processes that are executing on different computer systems tied together by a computer network. Communications may
be implemented via shared memory, in which two or more processes read and write to a shared section of memory, or
message passing, in which packets of information in predefined formats are moved between processes by the operating
system.
 Error Detection - The operating system needs to be detecting and correcting errors constantly. Errors may occur in the
CPU and memory hardware (such as a memory error or a power failure), in I/O devices (such as a parity error on disk, a
connection failure on a network, or lack of paper in the printer), and in the user program (such as an arithmetic
overflow, an attempt to access an illegal memory location, or a too-great use of CPU time).

2. List 3 main OS services for efficient operation for the system.


 Resource allocation - When multiple users or multiple jobs running concurrently, resources must be allocated to each of
them
 Many types of resources - CPU cycles, main memory, file storage, I/O devices.
 Accounting - To keep track of which users use how much and what kinds of computer resources
 Protection and security - The owners of information stored in a multiuser or networked computer system may want to
control use of that information, concurrent processes should not interfere with each other
 Protection involves ensuring that all access to system resources is controlled
 Security of the system from outsiders requires user authentication, extends to defending external I/O devices
from invalid access attempts

3. List three different methods of providing a user interface?


 Command Line Interface (CLI) - allows direct command entry Sometimes implemented in kernel, sometimes by systems
program
 Graphic User Interface (GUI) - form of user interface that allows users to interact with electronic devices through graphical
icons and visual indicators such as secondary notation, instead of text-based user interfaces, typed command labels or
text navigation.
 Touch Screen Interface - Touchscreen devices require new interfaces
 Mouse not possible or not desired
 Actions and selection based on gestures
 Virtual keyboard for text entry
 Voice commands.

4. How does an API (Application Program Interface) implement a system call?


 The API specifies a set of functions that are available to an application programmer, including the parameters that are
passed to each function and the return values the programmer can expect.

5. Describe 3 functions provided by the kernel.


 Provides the file system,
 CPU scheduling,
 Memory management, and
 Other operating-system functions; a large number of functions for one level.

6. What are the two basic goal groups that must be considered when designing an operating system?
 User goals and System goals
 User goals – operating system should be convenient to use, easy to learn, reliable, safe, and fast.
 System goals – operating system should be easy to design, implement, and maintain, as well as flexible, reliable,
error-free, and efficient.

7. Name at least two activities the operating system is responsible for in connection with disk management.
 Free space management.
 Storage allocation.
 Disk scheduling.

8. What is the name of the small piece of code that locates the kernel and loads it into main memory?
 Bootstrap program or bootstrap loader.

CHAPTER THREE (3) REVIEW QUESTIONS.

1. What is a Process Control Block (PCB) used for?


 A process represented in an operating system- also called task control block. Contains many pieces of information such
as process state, program counter, CPU registers, CPU scheduling information, memory management information,
Accounting information, I/O status information

2. Explain what happens in a Context Switch and why it is necessary?

 When CPU switches to another process, the system must save the state of the old process and load the saved state for
the new process via a context switch

Jkeako 12245 summary


MC415 OPERATING SYSTEM.
REVIEW QUIESTIONS.

3. With the aid of a neat diagram explain the set of process states in Sequence.

 As a process executes, it changes state


 new: The process is being created
 running: Instructions are being executed
 waiting: The process is waiting for some event to occur
 ready: The process is waiting to be assigned to a processor
 terminated: The process has finished execution

4. How are new processes created in UNIX and Linux systems?

 UNIX Process Creation. UNIX fork() creates a process. Creates a new address space. Copies text, data, & stack into new
address space. Provides child with access to open files. UNIX exec() allows a child to run a new program. UNIX wait()
allows a parent to wait for a child to terminate.
 The process is created by fork () system call. Fork () creates a new process from the existing process. The existing process
from which function called is known as parent process and newly created process is known as child process. Child
process has its own process ID. Fork ( ) takes no argument and return process ID. If successfully fork ( ) system call run, it
returns twice.

5. Explain the two fundamental models of inter-process communication?

 Independent &
 Cooperating

6. What is the function of the two system calls used with message-passing systems?

 send() &
 receive()

7. Provide at least two types of communication mechanisms in client-server systems.

 Sockets – Is an end point for the communication.


 Remote Procedure Calls – Remote procedure call (RPC) abstracts procedure calls between processes on networked
systems.
 Pipes – Acts as a conduit allowing two processes to communicate.

8. Give examples of the two types of pipes?

 Unnamed pipes – Unnamed pipes allow separate processes to communicate without having been designed explicitly to
work together. This allows tools quite narrow in their function to be combined in complex ways.
 Name pipes – is sometimes called a FIFO. FIFO stands for “First In, First Out” and refers to the property that the order of
bytes going in is the same coming out.

CHAPTER FOUR (4) REVIEW QUESTIONS.

1. Explain the difference, using examples, between threads and processes.

 Threads (of the same process) run in a shared memory space, while processes run in separate memory spaces.
 A process is an executing instance of a program. A thread is a path of execution within a process.
 E.g. when you start Word, the operating system creates a process and begins executing the primary thread of that
processes.

2. Explain how a web server might use threads to advantage.

 Specifying the number of threads used by the Web server. An HTTP request is processed by a thread. A thread, in turn,
can handle a number of network connections. You can specify the number of threads the Web server can process

3. Discuss 3 benefits of multithreaded programming.

 Responsiveness – may allow continued execution if part of process is blocked, especially important for user interfaces.
 Resource Sharing – threads share resources of process, easier than shared memory or message passing.
 Economy – cheaper than process creation, thread switching lower overhead than context switching.
 Scalability – process can take advantage of multiprocessor architectures.

4. Explain the difference, using examples, between concurrent execution on a single core system and parallel execution on a multi-
core system.

 Concurrent execution on a single core system – The switching between threads happens quickly enough that the
threads might appear to run simultaneously but the threads are not actually running simultaneously

Jkeako 12245 summary


MC415 OPERATING SYSTEM.
REVIEW QUIESTIONS.

 Parallel execution on a multi-core system – Each thread in the process can run concurrently on a separate processor,
resulting in parallel execution, which is true simultaneous execution.

5. Explain the difference, using examples, between Data parallelism and Task parallelism.

 Data parallelism – distributes subsets of the same data across multiple cores, same operation on each.
 Task parallelism – distributing threads across cores, each thread performing unique operation.

6. Discuss the difference between user level threads and kernel level threads, and how they can be related.

 User threads – management done by user-level threads’ library.


 Kernel threads – sometimes called Virtual Processors- Supported by the Kernel.

Linked file – a linked file can appear in two or more directories with each directory maintain a pointer to the file, thus allowing
multiple users to access

Path name unique – to enable the file to be found without confusion.

Jkeako 12245 summary

Das könnte Ihnen auch gefallen