Components of An Operating System

Download as ppt, pdf, or txt
Download as ppt, pdf, or txt
You are on page 1of 29

Components of an operating

system

An operating system is a software program that


provides an interface between the user and the
computer and manages thousands of applications.
Most computer systems are sold with an operating
system installed. Computers that are designed for
individual users are called Personal Computers (PCs).
PC operating systems are designed to control the
operations of programs such as Web browsers, word
processors, and e-mail programs.
There are three basic elements that make up the major
design components of any operating system. These
components are described as modular because each has
a distinct function and can be developed separately:

User interface – A user interacts with the operating system


through the user interface. The user interface is the part of
the operating system that can be used to issue commands
by either typing them at a command prompt or pointing
and clicking the mouse on a graphical user interface (GUI).
Kernel – This is the core of the operating system. The
kernel is responsible for loading and operating programs
or processes and managing input and output.
File management system – The file management system
is what the operating system uses to organize and
manage files. A file is a collection of data. Virtually all of
the information that a computer stores is in the form of a
file. There are many types of files, including program
files, data files, and text files. The way an operating
system organizes information into files is called the file
system. Most operating systems use a hierarchical file
system, which organizes files into directories under a tree
structure. The beginning of the directory system is called
the root directory.
Operating system functions
Regardless of the size and complexity of the computer and
its operating system, all operating systems perform the
same basic functions:
File and folder management – An operating system creates
a file structure on the computer hard drive where user data
can be stored and retrieved. When a file is saved, the
operating system saves it, attaches a name to it, and
remembers where it put the file for future use.
Management of applications – When a user requests a
program, the operating system locates the application and
loads it into the primary memory or RAM of the computer.
As more programs are loaded, the operating system must
allocate the computer resources.
Support for built-in utility programs –The operating system
uses utility programs for maintenance and repairs. Utility
programs help identify problems, locate lost files, repair
damaged files, and backup data. Figure shows the progress
of the Disk Defragmenter, which is found in Programs >
Accessories > System Tools.
Control to the computer hardware – The operating system
sits between the programs and the Basic Input Output
System (BIOS). The BIOS controls the hardware. All
programs that need hardware resources must go through
the operating system. The operating system can either
access the hardware through the BIOS or through the device
drivers as shown in Figure . The Windows 2000 NOS
bypasses the system BIOS and controls the hardware
directly.
All programs are written for a specific operating system.
Programs written for the UNIX operating system will not work
on a Windows operating system. The operating system
allows programmers to write applications without having to
consider hardware access. If the operating system did not
transmit information between the application and the
hardware, programs would have to be rewritten every time
they were installed on a new computer.
Operating system types and basic
terminology
To understand the capabilities of an operating system, it is
important to understand some basic terms. The following terms are
often used when comparing operating systems:
Multiuser – Two or more users can work with programs and share
peripheral devices such as printers at the same time.
Multitasking – The computer is capable of operating multiple
applications at the same time.
Multiprocessing – The computer can have two or more central
processing units (CPUs) that programs share.
Multithreading – A program can be broken into smaller parts that
can be loaded as needed by the operating system. Multithreading
allows individual programs to be multitasked.
What is DOS, and why learn about
it?
Microsoft developed the Disk Operating System
(DOS) in 1981. DOS, which is sometimes called MS-
DOS, was designed for the IBM PC. Windows 98
and Windows 2000 both support DOS commands to
reduce compatibility issues with older applications.
DOS is a collection of programs and commands that
are used to control overall computer operations in a
disk-based system. Figure shows an example of a
DOS prompt. There are three distinct sections that
make up the disk operating system:
Boot files – These are used during the boot process,
or system startup.
File management files – These enable a system to
manage its data in a system of files and folders.
Utility files – These enable the user to manage system
resources, troubleshoot the system, and configure the
system settings.
DOS file structure
To understand basic DOS commands, first
look at the structure of the disk. Programs and
data are stored on a disk the same way that a
document would be filed in a file cabinet.
Program and data files in DOS are grouped
together in directories. Directories are similar
to folders in a file cabinet. The files and
directories are organized for easy retrieval and
use. Directories can be kept inside other
directories, just like a folder can be placed
inside another folder. Nested directories are
referred to as subdirectories. Directories are
called folders in Windows operating systems.
Directory Structures and
Organization

Hard drives organize the disk into directories and


subdirectories. The main directory is called the root
directory. All other directories branch out from the
root directory, similar to the branches of a tree. In
MS-DOS, a graphical representation of the directory
organization is called a directory tree, as shown in
Figure . It is important to understand how DOS
organizes disks when preparing a hard drive for
Windows installation.
Any directory or file located within a directory is represented by the
directory name, followed by a backslash (\), followed by the name of
the file or subdirectory, such as C:\example\file.exe. In MS-DOS,
the format for specifying the path to a file is
C:\directory\subdirectory
\subdirectory\filename:

The C:\ specifies the C disk drive of the computer.


The back slash (\) after each item signifies the presence of a
directory or subdirectory.
The first back slash indicates the root directory, which is present on
all DOS disks.
The filename, which is found at the end of the path, is located in the
final subdirectory.
Overview of basic DOS commands

A DOS command is an instruction that DOS executes


from the command line. Internal commands such as dir
and copy are built into the COMMAND.COM program
and are always available when DOS is operating. Many
external commands such as format and xcopy are
individual programs that reside in the DOS directory.
What Is a Command Line?
The operating system usually provides the user
interface. In DOS, the main user interface is the
command line. The command line is the space that
follows the DOS prompt. For example, C:\ represents
the hard disk drive root directory in C:\>. The greater-
than sign (>) is called the prompt. All DOS commands
are typed to the right of the prompt and are executed
by pressing the Enter key. All DOS functions can be
entered and executed from the command line. For
example, all system files in the C directory can be
viewed by typing C:\>dir *.sys.
del – This command deletes named files. The del
and erase commands are synonymous. The
switch /p is commonly used to prompt the user for
confirmation before deleting each file. The format of
the del command is as follows:

del [directory\filename] /[switch]


The following switches are commonly used with the edit
command:

– b – Forces monochrome mode


– h – Displays the maximum number of lines possible for
the hardware
– r – Loads files in read-only mode
– [file] – Specifies initial files to load, wildcards and multiple
file specs can be given
format – This external command is used to erase all
the information from a floppy disk or a hard drive. The
format command can be used to prepare a hard drive
before installing a Windows OS. A typical format
command is as follows:

format [directory\filename] /[switch]

The following switches are commonly used with the


format command:
– q – Performs a quick format but does not clear the
FAT so file recovery is possible
– s – Copies system files to the formatted disk
– u – Performs unconditional format and all previous
data, including the FAT, is permanently erased

Note: The /s switch must be added when formatting to


make a system disk. If this switch is not used, the disk
can be reformatted or the DOS sys command can be
used.
fdisk – This external command allows users to delete and create partitions
on the hard disk drive. The fdisk command is commonly used to prepare
the hard drive before installing a Windows OS. This command is entered at
the command prompt as follows:

fdisk /[switch]

A commonly used switch is /status, it displays partition information when


used with the fdisk command.

scandisk – This command is a DOS program that is designed to detect


and repair errors on a hard drive or floppy disk. The scandisk command is
entered at the command prompt as follows:

scandisk /[switch]
Switches commonly used with the scandisk command are as
follows:

– all – Checks and repairs all local drives at once


– checkonly – Checks the drive for errors but does not make
repairs
– autofix – Automatically fixes errors and saves lost clusters by
default as files in the root directory

mem – This external command is used to display a table that


shows how memory is currently allocated. The mem command is
entered at the command prompt as follows:

mem /[switch]
Switches commonly used with the mem command are as follows:
– c – Lists the programs that are currently loaded into memory and
shows how much conventional and upper memory each program is
using
– d – Lists the programs and internal drivers that are currently loaded
into memory
– e – Lists the free areas of conventional and upper memory, which are
discussed later in this module
– p – Pauses after each screen of information

copy – This command is commonly used to copy one or more files from
one location to another. The copy command can also be used to create
new files. By using the copy con: command to copy files from the
keyboard console to the screen, files can be created and then saved to
disk. Switches commonly used with the copy command are as follows:
– y – Replaces existing files without providing a confirmation prompt
– -y – Displays a confirmation prompt before copying
over existing files
– a – Copies ASCII files and applies to the filename
preceding it and to all following filenames
– b – Copies binary files and applies to the filename
preceding it and to all following filenames
– v – Checks the copy to make sure that a file was
copied correctly and displays an error message if the
copy cannot be verified

more – Displays output one screen at a time. The


more command is entered at the command prompt as
follows: more [filename]
The cd, mkdir, rmdir, and deltree commands are slightly
different because they do not use switches. A brief
description of these commands is as follows:

cd – Changes or displays the current directory on the


specified drive
mkdir or md – Creates a new directory
rmdir or rd – Removes an empty directory, can only be
used after all subdirectories and files within the directory
have been deleted or moved
deltree – Deletes a directory, including all files and
subdirectories that are in it
Creating a DOS boot disk

Step 1 Start the computer.


Step 2 Insert a blank floppy disk in the drive.
Step 3 Type format A: /s at the command prompt
and press Enter.
Step 4 Type sys A: if the disk is already formatted and
press Enter.
DATE – Causes DOS to prompt the user for the date
TIME – Causes DOS to prompt the user for the date
and time
PROMPT=$P$G – Causes the active drive and directory
path to be displayed on the command line
SET TEMP=C:\TEMP – Sets up an area for holding
data temporarily in a directory called TEMP
PATH=C:\;C:\DOS;C:\MOUSE – This command creates
a specific set of paths that DOS uses to search for
executable .COM, .EXE, and .BAT files. In this
example, DOS will first search for executable files in
the root directory of C, followed by the DOS directory,
and finally the MOUSE directory.
DOSKEY – Loads the DOSKEY program into memory
SMARTDRV.EXE 2048 1024 – Configures the system for a
1-MB disk cache in DOS and a 2-MB cache for Windows
CD\ – Causes the DOS default directory to change to the
root directory
DIR – Causes a DOS DIR command to be performed
automatically
Editing system configuration files

SYSEDIT is a standard text editor used to edit system configuration


files such as CONFIG.SYS and AUTOEXEC.BAT. This utility can also
be used to edit the Windows initialization files that are generally
referred to as INI files. INI files are text files that users can edit with
a standard text editor utility such as SYSEDIT. INI files were created
when Windows 3.x was added to the DOS structure, and have been
included in the \Windows directory of more recent Windows
operating systems for backward compatibility. Common examples are
WIN.INI and SYSTEM.INI. CONFIG.SYS and AUTOEXEC.BAT are
found at the root directory C:\. To access these configuration files in
Windows 95, choose Start > Run and type sysedit
These files can also be accessed for editing in MS-
DOS by typing EDIT CONFIG.SYS or EDIT
AUTOEXEC.BAT at the DOS command prompt.

You might also like