1
|
What
is an "Operating System"?
"Operating
System" is a set of software which controls
and monitors a computer's resources to enable the
users and programmers to use these resources
easily and effectively.
An
Operating System is a program which interacts
directly with the hardware to provide an
interface to other system software and
application software whenever a system resource
is needed.
Operating
Systems hide the details of hardware of a
computer hence making life easier to the
programmer and user.
Operating
Systems are programs that organize sharing of
computer systems' resources among users and
application programs.
|
2
|
Describe
the "boot process" in detail.
- When
the power is turned on, the software stored in
the system ROM starts executing.
- This
software (called BIOS in the PC world) performs
the power on self-test procedure (POST).
- If
wll vital hardware modules pass this test (the
RAM, keyboard interface, display interface etc)
the BIOS software test local disks (floppies,
hard disks and/or CD drives) for accessability.
- If a
reasonable disk is accessible, BIOS checks
whether a Master Boot Record (MBR) exists on the
media (floppy or hard disk). The BIOS can know
whether a MBR exists by checking the contents of
the first track.
- BIOS
loads the contents of the MBR into RAM and CPU
starts executing this code. The MBR program then
start loading the operating into RAM. When the
load cycle is finished, control passes over to
the operating system hence the boot process ends.
|
3
|
Explain
the "interrupt" mechanism and when & how it
is used by the device management modules of an operating
system.
Most
devices in a computer are much much slower than the
CPU. When the Opsys wants to access a resource (like
a sector on a disk drive) it initiates the relevant
devices (like device controllers) and continues to
run any other task it can. When a device controller
completes its task (like when the requested sector is
ready) it sends an interrupt signal to the CPU also
identifying itself. Upon receiving this interrupt,
the operating system services this interrupt by
running appropriate programs.
Another
good example of I/O device interrupt is the keyboard.
Since it is not possible to predict when a key on the
keyboard will be pressed, it is very convenient to
design a keyboard interface so that an interrupt
signal is generated when a key is pressed. The
interrupt service routine of the opsys then decides
what to do with this key pressed.
Using
the interrupt mechanism with I/O devices increases
general computer performance because with the
interrupt mechanism, the opsys does not need to
continuously check all peripherals to see whether
something has to be done.
|
4
|
What
is the difference between a "device driver" and
"device controller"?
Since
the opsys is responsible for managing all the
resources in a computer, its code must be aware of
all the specifications and behaviour details of these
devices. Since this is practically impossible
(because the authors of the opsys cannot and should
not know all available peripherals in the market) the
peripheral manufacturer develops and delivers a piece
of software called device driver. Device Drivers run
as part of the operating system so that the opsys
knows the details of the peripheral.
Device
controllers are special hardware which operate the
peripheral according to commands/requests received
from the device driver software.
|
5
|
What
does "disk interleaving" mean?
When
sectors are read/writen from/to disk sectors, most
probably the next step will be reading/writing the
next sector. Since after each read/write sector
operation, a program must handle the data block a
smal time will be lost before starting processing the
next block of data (sector). In this small time the
"next" will miss the read/write heads and
the controller will have to wait till the needed
sector returns back to under the head. This will
cause serious delays.
If the
sectores are numbered by skipping a few sectors each
time, the chances that a sector will be just under or
very near to the read/write heads will increase. This
technique will increase disk performance very
significantly.
eg.
Instaed of numbering the sectors consequtively (1, 2,
3, 4, 5, 6, ... ) we number them as (1,12,7,2,13,8,3
...),
|
6
|
A
hard disk has 6 read/write heads, 4 disk plates, 2500
tracks/plate and 1000 sectors/track. If each sector is
512 Bytes (after formatting); what is the total capacity
of this disk drive? Your answer should clearly show your
calculations.
The
disk has 6 heads that means top side ot the top plate
and the bottom side of the bottom plate are not used.
That is only 6 surfaces are used in this disk.
6 x
2500 = 15,000 tracks on the disk
15,000
x 1000 sectors = 15,000,000 sectors
every
sector is 1/2 Kbytes, therefore the total capacity is
7.5 GBytes.
|