Network and Operating Systems

advertisement
Exam Code: INTI002_09
LIVERPOOL HOPE UNIVERSITY
MODULE CODE: INTI002
MODULE TITLE: NETWORKS & OPERATING SYSTEMS
December 2009, 1 HOUR 30 MINUTES
Instructions:
You are required to complete ALL parts of this timed assessment. You may
complete the parts in any order you wish.
Part 1 (20 marks)—Complete the Multiple Choice questions, there is only one available
answer per question. The answer sheet has been handed out separately to this document ensure that your name and ID number are on all answer sheets provided.
Part 2 (20 marks)—Complete the open questions.

Once completed you are to return this document with your answers
to the invigilator of the examination.
Part 1 – Multiple Choice (20 Marks)
1. Which of the following best describes an Operating System?
a. An operating system (commonly abbreviated to OS, O/S or kernel ) is an
interface between the CPU and software in a computer system. The OS is
responsible for the management and coordination of activities and the
sharing of the limited resources of the computer.To ensure hardware is
used efficiently.
b. An operating system (commonly abbreviated to OS, O/S or kernel ) is an
interface between hardware and software in a computer system. The OS is
responsible for the management and coordination of activities and the
sharing of the limited resources of the computer.To ensure hardware is
used efficiently.
c. An operating system (commonly abbreviated to OS, O/S or kernel) is a
piece of software that is designed to execute program instructions. The
computer would not function without an operating system.
d. An operating system (commonly abbreviated to OS, O/S or kernel) is a
piece of software that is designed to execute program instructions, the
operating system is also used to protect data. The computer would not
function without an operating system.
e. None of the above adequately describes an operating system.
2. Which of the following is NOT an operating system?
a. DOS
b. Solaris
c. Windows
d. ASP
e. Linux
3. Figure 1 is a block diagram showing the relationship between Cache and the CPU,
What does the block on the right represent?
a.
b.
c.
d.
e.
A CPU Register
Secondary Storage
Main Memory
Cache Memory
Outbound Storage
?
Figure 1 - Block Diagram showing relationship between CPU and Main Memory
4. Figure 2 is an example of a timing diagram, according to figure 2, which of the
following interrupt service routines are in the correct order of priority starting
with the lowest and ending with the highest assuming the interrupts occur at the
following times: 10, 15 and 20?
a. Printer Interrupt Service Routine, Communication Interrupt Service
Routine and Disk Interrupt Service Routine
b. Communication Interrupt Service, Printer Interrupt Service Routine,
Routine and Disk Interrupt Service Routine
c. Printer Interrupt Service Routine, Disk Interrupt Service Routine and
Communication Interrupt Service Routine
d. Disk Interrupt Service Routine, Printer Interrupt Service Routine and
Communication Interrupt Service Routine
e. They are all of equal priority
Figure 2 - Timing Diagram Example
5. Figures 3 is a representation of the fetch stage in the fetch and execute cycle.
Given that:



0011 will load AC from I/O
0111 will store AC to I/O
0100 will subtract contents of addressed word from AC
What is the action to be taken?
a.
b.
c.
d.
e.
The PC Counter will be incremented
The instruction in location 601 is copied to the IR
The instruction in location 602 is copied to the IR
The value in location 960 (1) is copied to the AC
The value in location 600 (3004) is copied to the AC
Memory
CPU Registers
600 3004
601
PC
601 4960
0
AC
602 7005
700
IR
I/O Module 4
100
I/0 Module 5
960
1
Figure 3 - Fetch Stage
10
6. Figures 4 is a representation of the execute stage in the fetch and execute cycle.
Given that:




0011 will load AC from I/O
0111 will store AC to I/O
0100 will subtract contents of addressed word from AC
0101 will add the contents of the addressed word to the AC
What is the action to be taken?
a.
b.
c.
d.
e.
The value in location 960 (1) is added to the AC
The instruction in location 601 is copied to the IR
The instruction in location 600 is copied to the IR
The value in location 960 (1) is copied to the AC
The value in location 960 (1) is subtracted from the AC
Memory
CPU Registers
600 3004
601 4960
601
9000
PC
AC
602 7005
4960
IR
I/O Module 4
100
I/0 Module 5
960
1
Figure 4 - Execute Stage
10
7. Most operating systems, until recently, featured a large monolithic kernel. Which
of the following best describes a monolithic kernel?
a. Most of what is thought of as OS functionality is provided in large kernels
called monolithic kernels. The functionality provided in the kernel
include scheduling, file system, networking, device drivers, memory
management, and more. Typically, a monolithic kernel is implemented as
a single process, with all elements sharing the same address space.
b. Most of what is thought of as OS functionality is provided in large kernels
called monolithic kernels. The functionality provided in the kernel
include scheduling, file system, networking, device drivers, memory
management, and more. Typically, a monolithic kernel is implemented as
multiple process, each of the multiple process have their own allocated
address space.
c. A monolithic kernel is based on architecture which assigns only a few
essential functions to the kernel, including address spaces, interprocess
communication (IPC), and basic scheduling. The monolithic approach
simplifies implementation, provides flexibility, and is well suited to a
distributed environment. In essence, a monolithic kernel interacts with
local and remote server processes in the same way, facilitating
construction of distributed systems.
d. A monolithic kernel is based on architecture which assigns only a few
essential functions to the kernel, including address spaces, interprocess
communication (IPC), and basic scheduling. The monolithic approach is
very complex in implementation but does provide greater flexibility. The
monolithic kernel is not well suited to a distributed environment. In
essence, a monolithic kernel interacts with local and remote server
processes in the same way, facilitating construction of distributed systems.
e. A monolithic kernel is swapped into and out of memory as required.
Initially the monolithic kernel is loaded into main memory, the monolithic
kernel would set up the address locations required for the next process, the
kernel would then load the job into memory. The monolithic kernel was
programmed using a Job Control Language (JCL) which allowed the
program to perform actions like: clear memory used by last job, load the
next program, find the data for the program, and jump to the start address
of a new program. Once a program had finished executing the monolithic
kernel would be loaded back into main memory and control would be
returned to the resident monitor.
8. A processor includes a set of registers that provide memory that is faster and
smaller than main memory. Processor registers functions. Which of the
following best describes these functions?
a. There are three classifications of register, User-visible, Control Status and
Operating System visible. The user can see the contents of the user visible
registers (for example, a word document process). The Control Status
registers are not visible by the user but are used by the operating system to
control program counters, instruction registers and others that are required
by the running process. The operating system registers are used by the
CPU for condition codes (also referred to as flags) and are bits typically
set by the processor hardware as a result of an operation.
b. There are two classifications of register, User-visible and Operating
System visible. The user can see the contents of the user visible registers
(for example, a word document process). The operating system registers
are not visible by the user but are used by the operating system to control
program counters, instruction registers and others that are required by the
running process.
c. Control and status registers enable the machine or assembly language
programmer to minimize main memory references by optimizing register
use. Paging registers are used by the processor to control the operation of
the processor and by privileged OS routines to control the execution of
programs.
d. User-visible registers enable the machine or assembly language
programmer to minimize main memory references by optimizing register
use. Control and status registers are used by the processor to control the
operation of the processor and by privileged OS routines to control the
execution of programs.
e. None of the above describes record blocking.
9. In the UNIX file system, six types of files are distinguished, which of the
following is the correct six types?
a. Read-Only, Write, Execute, Owner, Group and the World.
b. Read-Only, Write, Execute, Owner, Group and Everyone.
c. Regular, Directory, Special, Named tunnels, Links and Symbolic links.
d. Regular, Directory, Special, Named pipes, Links and Symbolic links.
e. None of the above explains are the correct six types.
10. Which of the following describes index node allocation?
a. index node is non-contiguous allocation and assignment of a file to a noncontiguous set of blocks. With non-contiguous allocation preallocation
strategies must be employed. This method of allocation uses variable size
portions.
b. Non-Contiguous allocation is the assignment of a file to a set of blocks,
the blocks are usually together but there can be allocations in other areas
of the disk. With non-contiguous allocation preallocation strategies must
be employed. This method of allocation uses fixed variable size portions.
c. File allocation is done on a block basis. Allocation is dynamic. Blocks
may not be contiguous. Index method keeps track of files.
d. File allocation is done on a set of blocks basis. Allocation is not dynamic.
Blocks are may not be contiguous. Index method keeps track of files.
e. None of the above describes Non-contiguous allocation correctly.
11. Which of the following best describes the ready processor state?
a. The process is in main memory and awaiting an event
b. The process is in secondary memory and awaiting an event
c. The process is in main memory and available for execution
d. The process is in secondary memory but is available for execution as soon
as it is loaded into main memory
e. The process is being executed by the CPU
12. Figure 5 shows an example of a inode structure which is typically used in UNIX
systems. Assuming block sizes are of 4Kb, which of the following is the accurate
statement?
a. A file of 68K is stored using 12 direct blocks and 5 single indirect blocks.
Pointers are used to the indirect blocks.
b. A file of 68K is stored using 12 direct blocks and 1 single indirect blocks
and 4 double indirect blocks. Pointers are used to the indirect blocks.
c. A file of 68K is stored using 1 single indirect blocks and 4 double indirect
blocks. Pointers are used to the indirect blocks.
d. A file of 68K is stored using 15 single indirect blocks. Pointers are used
to the indirect blocks.
e. A file of 68K is stored using 15 double indirect blocks. Pointers are used
to the indirect blocks.
Figure 5 - Structure of inode and File
13. Traditional UNIX file access control is best described as which of the following
statements?
a. There are three classes; these are owner class, group class and other class.
Each of these classes use 3 bits, the bits allow access controls for the file
to be set to read, write and execute.
b. There are four classes; these are owner class, group class, profile class and
other class. Each of these classes use 3 bits, the bits allow access controls
for the file to be set to read, write and execute.
c. UNIX file systems are limited in terms of access control; however, file
access can be set to hidden, read only and archive.
d. UNIX file systems are limited in terms of access control; however, file
access can be set to hidden, read only and execute.
e. None of the above accurately describes UNIX file access control
14. Which of the following best describe the steps involved in creating a process?
a. The process is assigned an ID, space is allocated for the process, the
process control block is initialised, the appropriate links are set up and the
creation or expanding of other data structures occur.
b. The process is assigned an ID, the process is passed to the CPU, space is
allocated for the process, the process control block is initialised, the
appropriate links are set up and the creation or expanding of other data
structures occur.
c. The process is assigned a parent, the process is passed to the CPU, space is
allocated for the process, the process control block is initialised, the
appropriate links are set up and the creation or expanding of other data
structures occur.
d. The process is assigned a parent, space is allocated for the process, the
process control block is initialised, the appropriate links are set up and the
creation or expanding of other data structures occur.
e. None of the above accurately describes a process.
15. Which of the following best describes the role of the process control block
(PCB)?
a. The process control block is the most important data structure in the OS.
Each PCB contains all of the information about a process that is needed by
the OS.
b. The process control block is the most important disk structure in the OS.
Each PCB contains all of the information about a block and the block size
that is needed in order to be process by the OS.
c. The process control block is the most important inode disk structure in the
OS. Each PCB contains all of the information about a block and the
information about the indirect, single direct, double direct and triple direct
pointers that is needed in order to be processed by the OS.
d. The process control block is the most important data structure in the OS.
Each PCB contains all of the information about a process, the instructions
and the data stacks that are needed by the OS.
e. None of the above correctly describes a process control block.
16. What is the name of the program responsible for switching the processor from one
process to another?
a. The switcher
b. The dispatcher
c. The re-assigner
d. The scheduler
e. None of the above
17. When considering dynamic memory partitioning, partitions are of variable length
and number. A Process is allocated exactly as much memory as required.
However, this leads to external fragmentation and holes in memory. There are
typically 3 algorithms to assign a process to a hole in memory, which of the
following correctly lists the three?
a. Blocking, Segmentation and Paging.
b. Blocking, Locking and Pile.
c. Best Fit, First Fit and Next Fit
d. Recommended Fit, Ready Fit, Acquired Fit
e. None of the above.
18. A UNIX file system resides on a single logical disk or disk partition and is laid
out using four elements. Which of the following accurately lists the elements?
a. Boot Block, superblock, inode table and data blocks.
b. First Boot Block, Second super boot block, file allocation table and data
blocks.
c. Boot Block, superblock, NTFS table and data blocks (which are 4Kb).
d. Boot Block, superblock, inode table and data blocks.
e. None of the above
19. Which of the following disk storage concepts does NTFS make use of?
a. Volume, Block and FAT
b. Sector, Cluster and Volume
c. Array, Table and Database
d. Volume, Cluster and Array
e. None of the above
20. Which of the following best describes the journaling feature in a file system?
a. A journaling file system is a file system that logs changes to a journal
(usually a circular log in a dedicated area of the file system) before
committing them to the main file system. Such file systems are less likely
to become corrupted in the event of power failure or system crash
b. A journaling file system is a file system that copies all files not only to the
hard disk but firstly, to a reserved space on disk called a journal (usually
in a dedicated area of the hard disk) before committing them to the main
file system. Such file systems are less likely to become corrupted in the
event of power failure or system crash
c. A journaling file system is that of which fixed size blocks must be used.
This allows the file system manager to record all changes in the master file
table and the second file table called a journal. If the master file table
becomes corrupt it is replaced by the journal.
d. A journaling file system is that of which variable size blocks must be used.
This allows the file system manager to record all changes in the master file
table and the second file table called a journal. If the master file table
becomes corrupt it is replaced by the journal.
e. None of the above accurately explains a the journaling feature in a file
system.
Part 2 – Open Questions (20 Marks)
21. Briefly discuss the chained file organisation; you may illustrate your answer with
a diagram.
[5 marks]
22. Paging is a memory management scheme. Highlight the characteristics of this
scheme.
[5 marks]
23. This figure shows a process state transition diagram. Explain the diagram
[5 marks]
24. At some time, a running process is stopped and the OS assigns another process to
the running state and turns control over to that process. There are generally three
mechanisms for switching a process (not finishing), list the three mechanisms and
the use of the mechanisms.
[5 marks]
Download