0% found this document useful (0 votes)
20 views20 pages

Os 03

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

Os 03

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

Structure of OS

Quratulain Leghari
Chapter covers
• Major functions of OS
• Common Components of OS
Major functions of OS
•Major Functions of Operating System
• Resource management
• Data management
• Job management
• Standard Means Of Communication Between User And
Computer
Resource Management

• The resource management function of an OS allocates


computer resources such as CPU time, main memory,
secondary storage, and input and output devices for use.
Types of Resources
• CPU Scheduling:
• Memory Management:
• File System Management:
• I/O Device Management:
• Network Resource Management:
• Concurrency Control:
• Power Management:
• Load Balancing:
• Performance Monitoring and Tuning:
• Security and Access Control:
Data Management

• The data management functions of an OS govern the input


and output of data and their location, storage, and retrieval.
• It also is responsible for storing and retrieving information on
disk drives and for the organization of that information on the
drive.
Job Management

• The job management function of an OS prepares, schedules,


controls, and monitors jobs submitted for execution to ensure
the most efficient processing.
• A job is a collection of one or more related programs
• and their data.
Standard Means of Communication between
User and Computer
• The OS also establishes a standard means of communication
between users and their computer systems.
• It does this by providing a user interface and a standard set of
commands that control the hardware.
Common System Components
 Process Management
 Main Memory Management
 File System Management
 I/O System Management
 Mass-Storage Management
 Networking
 Command Interpreter
 Protection and Security
 Error detection/response
 Accounting
Process Management
 A process is a program in execution. It is a unit of work within the system.
 Program is a passive entity, process is an activity entity.
 The operating system is responsible for the following activities in connection with
process management.
 Creating and deleting both user and system processes.
 Suspending and resuming process.
 Providing mechanisms for process synchronization.
 Providing mechanisms for process communication.
 Providing mechanisms for deadlock handling.
Process Management
 A Process needs resources to accomplish its task.
 CPU, memory, I/O devices, files
 Initialization data

 Process termination requires reclaim of any reusable resources. Typically a system


has many processes, some user, some operating system running
concurrently on one or more CPUs
 Concurrency by multiplexing the CPUs among the processes/threads.
Main Memory Management
 All data in memory before and after processing.
 All instructions in memory in order to execute.
 Memory management determines what is in memory and how to handle it
 Optimizing CPU utilization and computer response to users.
 Memory management activities:
 Keeping track of which parts of memory are currently being used and by whom.
 Deciding which processes (or parts) and data to move into and out of memory.
 Allocating and de-allocating memory space as needed.
File System Management
 A file is a collection of related information defined by its creator.
 Commonly, files represent programs (both source and object forms) and data.
 Files are usually organized into directories.
 OS activities include:
 Creating and deleting files and directories.
 Primitives to manipulate files and directories.
 Mapping files onto secondary storage.
 Backup files onto stable (non-volatile) storage media.
I/O System Management
 One purpose of OS is to hide the unusual of hardware devices from the user.
 I/O subsystem is responsible for:
 Memory management of I/O including:
 Buffering (storing data temporarily while it is being transferred)
 Caching (storing parts of data in faster storage for performance)
 Spooling (CPU track I/O devices for communication)
 Interrupts (I/O communication during execution of other process)
 DMA (Direct Memory Access, to transfer data from one memory to another)
 General device-driver interface.
 Drivers for specific hardware devices.
Mass-Storage Management
 Usually a disk is used to store data that does not fit in main memory or data that must
be kept permanently.
 Entire speed of computer operations depends on disk subsystem and its algorithms.
 OS activities:
 Free-space management
 Storage allocation
 Disk scheduling
 Some storage need not to be fast:
 Storage includes optical storage, magnetic tape
 Varies between WORM (write-once, read-many times) and RW (read-write)
Networking
 The processors in the system are connected through a communication network.
 Communication takes place using a protocol.
 A networked/distributed system provides user access to various system resources.
 Access to a shared resource allows:
 Computation Speed Up
 Increased data availability
 Enhanced reliability
Command Interpreter
 The program that reads and executes commands given to the
operating system
 Examples of command-line interpreters are command (DOS), shell
(UNIX)
 In windows and in some other operating systems have GUI Interface
– WIMP (Windows, Icons, Menu and Pointing device)
Protection and Security
 Protection – any mechanism for controlling access of processes or users to both system
and user resources.
 Security – defense of the system against internal and external attacks, with huge
range, including:
 Denial of Service
 Worms
 Viruses
 Identity theft
 Theft of Service
Error Detection/Response
 Error Detection
 Internal and external hardware errors
 Memory error
 Device failure
 Software Errors
 Arithmetic flow
 Access forbidden memory locations
 Error Response
 Simply report error to the application
 Retry the operation
 Abort the operation
Accounting
 Accounting keeps track of records that users use how much and what kinds of computer
resources
 Accounting:
 Collect statistics on resource usage
 Monitor performance (e.g. response time)
 Used for system parameter tuning to improve performance
 Useful for anticipating future enhancements
 Used for billing users

You might also like