0% found this document useful (0 votes)
34 views8 pages

Unit 1 OS Basic Concepts Structure and Services

Uploaded by

Jessa Siaton
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
34 views8 pages

Unit 1 OS Basic Concepts Structure and Services

Uploaded by

Jessa Siaton
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 8

2/11/2024

What is an Operating System?

 A program that acts as an intermediary between a user of


a computer and the computer hardware.
 A resource sharing and management interface software
Unit 1: Operating System Overview that helps to increase the availability of the computer to
its user while facilitating interaction with the hardware.
and Basic Concepts  Operating system goals:
 Execute user programs and make solving user
problems easier.
 Make the computer system convenient to use.
 It coordinates all the hardware and software
components of a computer.
 Use the computer hardware in an efficient manner.

Operating System Definition Operating System Definition (Cont.)


 No universally accepted definition
 “Everything a vendor ships when you order an operating
 OS is a resource allocator system” is good approximation
 Manages all resources  But varies wildly
 “The one program running at all times on the computer” is
 Decides between conflicting requests the kernel. Everything else is either a system program
for efficient and fair resource use (ships with the operating system) or an application program
 OS can be also describe as:
 OS is a control program  Multi Tasking – one or more programs are allowed to run at a time.
 Preemptive – OS parcels out CPU time slices to each program
 Controls execution of programs to (OS/2, New versions of Windows, Win NT, UNIX)

prevent errors and improper use of the  Cooperative – each program can control the CPU for as long as it needs it.
(Old versions of Windows, MultiFinder - Mac Computers)
computer
 Single Tasking – only one program can run at a time. (DOS, Palm OS)

NOTE: OS has 2 main parts, the main OS and the Kernel (Heart of the
program)
2/11/2024

Multi-Tasking OS Single-Tasking OS

Computer Hardware and Software What does a modern operating system


Structure do?
 Provides Abstractions Hardware has low-level physical resources
with complicated, idiosyncratic interfaces. OS provides abstractions
that present clean interfaces. Goal: make computer easier to use.
Examples: Processes, Unbounded Memory, Files, Synchronization
and Communication Mechanisms.
 Provides Standard Interface Goal: portability. Unix runs on many
very different computer systems. To a first approximation can port
programs across systems with little effort.
 Mediates Resource Usage Goal: allow multiple users to share
resources fairly, efficiently, safely and securely. Examples:
 Multiple processes share one processor. (preemptable resource)
 Multiple programs share one physical memory (preemptable
resource).
 Multiple users and files share one disk. (non-preemptable
resource)
 Multiple programs share a given amount of disk and network
bandwidth (preemptable resource).
 Consumes Resources Solaris takes up about 8Mbytes physical
memory.
2/11/2024

System Boot System Boot

 Operating system must be made available to  bootstrap program is loaded at power-up


hardware so hardware can start it or reboot
 Small piece of code – bootstrap loader,
locates the kernel, loads it into memory, and
 Typically stored in ROM or EPROM,
starts it generally known as firmware
 Sometimes two-step process where boot  Initializes all aspects of system
block at fixed location loads bootstrap loader
 Loads operating system kernel and
 When power initialized on system, execution starts execution
starts at a fixed memory location
Firmware used to hold initial boot code

Evolution of Operating Systems Classification of Operating Systems

 Serial Processing - Performs all the instructions into a


Sequence Manner or the Instructions those are given by the
user will be executed by using the FIFO Manner
 Simple Batch System is where the computer runs one
application at a time and move from one job to other
 Multiprogrammed Batch Systems, In this the operating
system, picks and begins to execute one job from memory.
Once this job needs an I/O operation operating system
switches to another job (CPU and OS always busy).
 Time Sharing Systems. In fact time sharing systems are an
extension of multiprogramming systems. In time sharing
systems the prime focus is on minimizing the response time,
while in multiprogramming the prime focus is to maximize
the CPU usage. (Unix, Linux, Windows 2000 Server)
2/11/2024

Classification of Operating Systems


Operating System Structure
(Cont.)
 Multiprocessor systems consists of several processors
 The design of an operating system architecture
that share a common physical memory. Multiprocessor
system provides higher computing power and speed. (GPU) traditionally follows the separation of
 Distributed operating systems is the availability of
concerns principle. This principle suggests
powerful and inexpensive microprocessors and advances in structuring the operating system into relatively
communication technology. (Windows 2003/2008/2012, independent parts that provide simple individual
Ubuntu) features, thus keeping the complexity of the design
 Real-time operating system (RTOS) is an operating manageable.
system intended to serve real time application that process
data as it comes in, mostly without buffer delay. (PSOS, RT-
Linux, Lynx)
 Handheld Operating Systems are designed to run on
machines that have lower speed processors and less
memory, they were designed to use less memory and
require fewer resources. (PalmOS, Windows CE)

Operating System Structure Simple Structure

 Typical approaches to structuring the  Operating systems such as MS-DOS and the
operating system. original UNIX did not have well-defined structures.
 Simple Structure  There was no CPU Execution Mode (user and
 MonolithicSystems kernel), and so errors in applications could cause
 Layered Systems the whole system to crash.
 Microkernel Systems
2/11/2024

Monolithic Approach Layered Approach

 Functionality of the OS is invoked with simple function calls  This allows implementers to change the inner workings, and
within the kernel, which is one large program. increases modularity.

 Device drivers are loaded into the running kernel and  As long as the external interface of the routines don’t change,
developers have more freedom to change the inner workings of the
become part of the kernel.
routines.
 With the layered approach, the bottom layer is the hardware, while
the highest layer is the user interface.

Microkernels Operating System Services

This structures the operating system by removing all  One set of operating-system services provides functions
nonessential portions of the kernel and implementing them as that are helpful to the user:
system and user level programs.
 User interface - Almost all operating systems have a user
 Generally they provide minimal process and memory management,
and a communications facility. interface (UI)
 Communication between components of the OS is provided by  Varies between Command-Line (CLI), Graphics User
message passing. Interface (GUI)
 Program execution - The system must be able to load a
program into memory and to run that program, end execution,
either normally or abnormally (indicating error)
 I/O operations - A running program may require I/O, which may
involve a file or an I/O device.
 File-system manipulation - The file system is of particular
interest. Obviously, programs need to read and write files and
directories, create and delete them, search them, list file
Information, permission management.
2/11/2024

Operating System Services (Cont.) Operating System Services (Cont.)


 Another set of OS functions exists for ensuring the efficient operation of
the system itself via resource sharing
 One set of operating-system services provides functions  Resource allocation - When multiple users or multiple jobs running
that are helpful to the user (Cont): concurrently, resources must be allocated to each of them
 Many types of resources - Some (such as CPU
 Communications – Processes may exchange information, on
cycles,mainmemory, and file storage) may have special allocation
the same computer or between computers over a network code, others (such as I/O devices) may have general request and
release code.
 Communicationsmay be via shared memory or through
 Accounting - To keep track of which users use how much and what
message passing (packets moved by the OS)
kinds of computer resources
 Error detection – OS needs to be constantly aware of possible  Protection and security - The owners of information stored in a
errors multiuser or networked computer system may want to control use of
that information, concurrent processes should not interfere with each
 May occur in the CPU and memory hardware, in I/O devices, other
in user program  Protection involves ensuring that all access to system resources
is controlled
 Foreach type of error, OS should take the appropriate action
 Security of the system from outsiders requires user authentication,
to ensure correct and consistent computing extends to defending external I/O devices from invalid access
 Debugging
facilities can greatly enhance the user’s and attempts
programmer’s abilities to efficiently use the system  If a system is to be protected and secure, precautions must be
instituted throughout it. A chain is only as strong as its weakest
link.

Operating System Services (Cont.) User Operating System Interface - CLI

 Another set of OS functions exists for ensuring the CLI allows direct command entry
efficient operation of the system itself via resource  Sometimes implemented in
sharing kernel, sometimes by
 Crash Protection – The ability to isolate systems program
application errors from affecting other applications  Sometimes multiple flavors
or the OS itself. implemented – shells
 Primarilyfetches a
 Extensible – The ability to easily expand the
command from user and
capabilities of the OS as updates becomes
executes it
available.
– Sometimes commands
 Utilities – a set of common utilities for built-in, sometimes just
maintaining the health of our disks (scandisk and names of programs
defrag) and performing backups.
2/11/2024

User Operating System Interface - GUI Core Functions of an Operating System

 User-friendly desktop metaphor interface


 The OS is the software program that
 Usually mouse, keyboard, and monitor
 Icons represent files, programs, actions, etc
really understands the hardware and
 Various mouse buttons over objects in the interface knows how to work with it. Because
cause various actions (provide information, options, the OS is so knowledgeable, the
execute function, open directory (known as a folder)
 Invented at Xerox PARC
programs, the hardware devices, and
 Many systems now include both CLI and GUI interfaces the user don't have to be as aware.
 Microsoft Windows is GUI with CLI “command” shell
 Apple Mac OS X as “Aqua” GUI interface with UNIX
kernel underneath and shells available
 Solaris is CLI with optional GUI interfaces (Java
Desktop, KDE)

Operating system functions Comparison of the Core Functions of


Windows and DOS

Operating system function Example DOS Windows


System supervision manages memory, starts and controls  DOS program run  Windows run in
processes in real-mode. protected mode.
DOS has access Application memory
Services to hardware drivers for various devices (drives, displays, to only 1 Mb of spaces may be
etc.) memory space
System supervision isolated from one
with only 640 Kb
Services to software support to other programs such as the user available at most another reducing
inter-face (UI), file systems, etc. to run applications. the possibility of
The OS and one program
Communications services redirects requests for information from the applications share corrupting the
local system to an external one; ... the same memory memory space of
space often another. Virtual
leading to conflict memory is
and crashes. available.
2/11/2024

Comparison of the Core Functions of Comparison of the Core Functions of


Windows and DOS (Cont.) Windows and DOS (Cont.)
DOS Windows DOS Windows
 Interacting with  Windows  File I/O is  Windows makes
devices is generally implements shared
handled through the 32 and 64-bit drivers handled use of the virtual
installation of a for most devices through file allocation
device driver. offering greater
Services to Device driver are speed, greater Services to Software commands to table (VFAT),
Hardware hardware specific resource sharing, the BIOS and which allows
and can be and less chance for the such features as
software specific as driver conflicts. Plug-
well. The possibility and-Play devices organization of 255 character
for conflicts cooperatively the file filenames.
between device configure
drivers is ever- themselves at start- allocation
present. up. table(FAT)

Comparison of the Core Functions of


Windows and DOS
DOS Windows
 When the name of a  Initiating a program
program is entered under Windows is
at the command accomplished by the
prompt createProcess End of Unit 1
command.com is command stored in
Communication
responsible for the Kernal32.dll in the
Services
locating the program WINDOWS/SYSTEM
and passing its 32 folder. This
name on the EXEC command initiates the
functions which threads, and
begins program schedules the
execution. Only one processor time
process can happen necessary to run a
at a time. Filename program in a multi-
extension of .BAT, tasking environment.
.COM, or .EXE

You might also like