SlideShare a Scribd company logo
Chapter 2
Services and Components of Operating System
By
Ms. H. C Kunwar
Lecturer
RAISONI GROUP OF INSTITUTIONS
RAISONI GROUP OF INSTITUTIONS
RAISONI GROUP OF INSTITUTIONS
Operating System Services
• Operating systems provide an environment for execution of programs and
services to programs and users
1. User interface : -
Almost all operating systems have a user interface (UI) Varies between
Command-Line (CLI), Graphics User Interface (GUI), Batch
2. 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).
3. I/O operations : -
A running program may require I/O, which may involve a file or an I/O device
4. File-system manipulation :-
The file system is of particular interest. Programs need to read and write files
and directories, create and delete them, search them, list file Information,
permission management.
RAISONI GROUP OF INSTITUTIONS
Operating System Services (Cont.)
5. Communications :–
Processes may exchange information, on the same computer or between
computers over a network Communications may be via shared memory or
through message passing (packets moved by the OS)
6. Error detection :–
OS needs to be constantly aware of possible errors
• May occur in the CPU and memory hardware, in I/O devices, in user
program
• For each type of error, OS should take the appropriate action to
ensure correct and consistent computing
• Debugging facilities can greatly enhance the user’s and programmer’s
abilities to efficiently use the system
RAISONI GROUP OF INSTITUTIONS
Operating System Services (Cont.)
6. Resource allocation :-
When multiple users or multiple jobs running concurrently, resources must be
allocated to each of them Many types of resources - Some (such as CPU cycles, main
memory, and file storage) may have special allocation code, others (such as I/O
devices) may have general request and release code
7. Accounting :-
To keep track of which users use how much and what kinds of computer resources
8. Protection and security:-
The owners of information stored in a multiuser or networked computer system may
want to control use of that information, concurrent processes should not
interfere with each other
• Protection involves ensuring that all access to system resources is controlled
• Security of the system from outsiders requires user authentication, extends
to defending external I/O devices from invalid access attempts
RAISONI GROUP OF INSTITUTIONS
A View of Operating System Services
RAISONI GROUP OF INSTITUTIONS
System Calls
• System call is an interface between a running program and operating system. It
allows user to access services provided by operating system. This system calls are
procedures written using C,C++ and assembly language instructions.
• The interface between a process and an operating system is provided by system
calls.
• Each operating system has its own name for each system call.
• Each system call is associated with a number that identifies itself
• System calls are usually made when a process in user mode requires access to a
resource. Then it requests the kernel to provide the resource via a system call.
RAISONI GROUP OF INSTITUTIONS
System Call Implementation
• Typically, a number associated with each system call System-call interface
maintains a table indexed according to these numbers.
• The system call interface invokes intended system call in OS kernel and
returns status of the system call and any return values.
• The caller need know nothing about how the system call is implemented
• Just needs to obey API and understand what OS will do as a result
call.
• Most details of OS interface hidden from programmer by API.
RAISONI GROUP OF INSTITUTIONS
How System Call Implemented
RAISONI GROUP OF INSTITUTIONS
Types of System Calls
• Process control
– end, abort
– load, execute
– create process, terminate process
– get process attributes, set process attributes
– wait for time
– wait event, signal event
– allocate and free memory
• File management
– create file, delete file
– open, close file
– read, write, reposition
– get and set file attributes
RAISONI GROUP OF INSTITUTIONS
Types of System Calls (Cont.)
• Device management
– request device, release device
– read, write, reposition
– get device attributes, set device attributes
– logically attach or detach devices
• Information maintenance
– get time or date, set time or date
– get system data, set system data
– get and set process, file, or device attributes
• Communications
– create, delete communication connection
– send, receive messages
– transfer status information
– attach and detach remote devices
RAISONI GROUP OF INSTITUTIONS
Examples of Windows and
Unix System Calls
RAISONI GROUP OF INSTITUTIONS
Operating System Components
• Process Management
• Main Memory Management
• Secondary-Storage Management
• I/O System Management
• File Management
RAISONI GROUP OF INSTITUTIONS
Process Management
• A process is a program in execution. A process needs certain resources,
including CPU time, memory, files, and I/O devices, to accomplish its task.
• The operating system is responsible for the following activities in
connection with process management.
– Process creation and deletion.
– process suspension and resumption.
– Provision of mechanisms for:
• process synchronization
• process communication
RAISONI GROUP OF INSTITUTIONS
Main-Memory Management
• Memory is a large array of words or bytes, each with its own
address. It is a repository of quickly accessible data shared by the
CPU and I/O devices.
• Main memory is a volatile storage device. It loses its contents in the
case of system failure.
• The operating system is responsible for the following activities in
connections with memory management:
– Keep track of which parts of memory are currently being used
and by whom.
– Decide which processes to load when memory space becomes
available.
– Allocate and deallocate memory space as needed.
RAISONI GROUP OF INSTITUTIONS
Secondary-Storage Management
• Since main memory (primary storage) is volatile and too small to
accommodate all data and programs permanently, the computer
system must provide secondary storage to back up main memory.
• Most modern computer systems use disks as the principle on-line
storage medium, for both programs and data.
• The operating system is responsible for the following activities in
connection with disk management:
– Free space management
– Storage allocation
– Disk scheduling
RAISONI GROUP OF INSTITUTIONS
I/O System Management
• The I/O system consists of:
– A buffer-caching system
– A general device-driver interface
– Drivers for specific hardware devices
RAISONI GROUP OF INSTITUTIONS
File Management
• A file is a collection of related information defined by its creator.
Commonly, files represent programs (both source and object forms) and
data.
• The operating system is responsible for the following activities in
connections with file management:
– File creation and deletion.
– Directory creation and deletion.
– Support of primitives for manipulating files and directories.
– Mapping files onto secondary storage.
– File backup on stable (nonvolatile) storage media.
RAISONI GROUP OF INSTITUTIONS
Use of Operating System Tools
Following are the operating tools:
 User Management
 Security policy
 Device Management
 Performance Monitor
 Task Scheduler
RAISONI GROUP OF INSTITUTIONS
Use of Operating System
Tools(cont..)
1. User Management:
• User management includes everything from creating a user to deleting a user on
your system. User management can be done in three ways on a Linux system.
• Command line tools include commands like useradd, userdel, usermod, passwd,
etc. These are mostly used by the server administrators.
• Useradd: With useradd commands you can add a user.
• Syntax: useradd -m -d /home/ - c ""
• Example: useradd -m -d /home/xyz -c "xyz" xyz
RAISONI GROUP OF INSTITUTIONS
Use of Operating System
Tools(cont..)
2. Device Management:
• Device management is the process of managing the implementation, operation and
maintenance of a physical and/or virtual device.
• All Linux device files are located in the /dev directory, which is an integral part of
the root (/) file system because these device files must be available to the operating
system during the boot process.
• Example: ls –l /dev
• Above example gives the list of device file from kernel.
RAISONI GROUP OF INSTITUTIONS
Use of Operating System
Tools(cont..)
3. Performance Monitor:
• It is very tough job for every system or network administrator to monitor and debug
Linux System Performance problems every day.
• The commands discussed below are some of the most fundamental commands
when it comes to system analysis and debugging Linux server issues such as:
• vmstat: Virtual memory statistics
• The vmstat command reports information about processes, memory, paging, block
IO, traps, and cpu activity.
• Eg. $ vmstat 3
RAISONI GROUP OF INSTITUTIONS
Use of Operating System
Tools(cont..)
3. Security Policy:
• Security policies cover all preventative measures and techniques to ensure the
safeguarding of an OS, the network it connects to, and the data which can be
stolen, edited or deleted.
• OS security policies and procedures cover a broad area (i.e. from threats to
attacks), there are many ways to address them.
• Some of these areas include:
• Ensuring systems are patched or updated regularly.
• Installing and updating anti-virus software.
• Installing a firewall and ensuring it is configured properly to monitor all
incoming and outgoing traffic.
• Implementing user management procedures secure user accounts and
privileges.
RAISONI GROUP OF INSTITUTIONS
Use of Operating System
Tools(cont..)
3. Task Scheduler:
• The Task Scheduler is a tool included
with Windows that allows predefined
actions to be automatically executed
whenever a certain set of conditions is
met.
• For example, you can schedule a task to
run a backup script every night, or send
you an e-mail whenever a certain system
event occurs
Thank You
End of Chapter 2

More Related Content

PPT
Os structure
PPT
Operating-System Structures
PDF
osunit1ppt-23011904470yuoij4-685c22ef.pdf
PPTX
OS UNIT 1 PPT.pptx
PPTX
operating system calls input and output by (rohit malav)
PPTX
operating system structures
PDF
System Structure Notes : comprehensive study
PPT
System Calls and Components of OS . ppt
Os structure
Operating-System Structures
osunit1ppt-23011904470yuoij4-685c22ef.pdf
OS UNIT 1 PPT.pptx
operating system calls input and output by (rohit malav)
operating system structures
System Structure Notes : comprehensive study
System Calls and Components of OS . ppt

Similar to osy_unit_2.pptxservices and components of OS (20)

PPTX
Services and system calls
PPT
ch3 - operating system structures.ppt
PPT
ch2_OS Structures.ppt To discuss the various ways of structuring an operatin...
PDF
operating system structure
PPTX
PPTX
Design Of Operating System_Lecture_OS_2.pptx
PPT
OS Services, System call, Virtual Machine
PPTX
2. Operating System Structure,Services,Call, Design and Implementation.pptx
PPTX
Lecture_02_Operating System Structures Operating Systems
PPT
Operating System 2
PDF
CH02.pdf
PPT
Services of OS.ppt Two types of services
PDF
Operating System Structure Part-I.pdf
PPTX
Operating Systems
PPT
PPT
ch2-system structure.ppt
PPT
Ch2 system structure
PDF
chapter 3 opreating system lecture note and its is impaortamt concept for mn
PPTX
Operating System-unit 1.pptxX X A A A A A A A A A A
PDF
R20CSE2202-OPERATING-SYSTEMS .pdf
Services and system calls
ch3 - operating system structures.ppt
ch2_OS Structures.ppt To discuss the various ways of structuring an operatin...
operating system structure
Design Of Operating System_Lecture_OS_2.pptx
OS Services, System call, Virtual Machine
2. Operating System Structure,Services,Call, Design and Implementation.pptx
Lecture_02_Operating System Structures Operating Systems
Operating System 2
CH02.pdf
Services of OS.ppt Two types of services
Operating System Structure Part-I.pdf
Operating Systems
ch2-system structure.ppt
Ch2 system structure
chapter 3 opreating system lecture note and its is impaortamt concept for mn
Operating System-unit 1.pptxX X A A A A A A A A A A
R20CSE2202-OPERATING-SYSTEMS .pdf
Ad

Recently uploaded (20)

PDF
Embodied AI: Ushering in the Next Era of Intelligent Systems
PDF
III.4.1.2_The_Space_Environment.p pdffdf
PPTX
FINAL REVIEW FOR COPD DIANOSIS FOR PULMONARY DISEASE.pptx
PDF
R24 SURVEYING LAB MANUAL for civil enggi
PDF
BIO-INSPIRED HORMONAL MODULATION AND ADAPTIVE ORCHESTRATION IN S-AI-GPT
PPTX
6ME3A-Unit-II-Sensors and Actuators_Handouts.pptx
PPT
Introduction, IoT Design Methodology, Case Study on IoT System for Weather Mo...
PDF
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
PDF
Human-AI Collaboration: Balancing Agentic AI and Autonomy in Hybrid Systems
DOCX
573137875-Attendance-Management-System-original
PPTX
Engineering Ethics, Safety and Environment [Autosaved] (1).pptx
PPTX
Construction Project Organization Group 2.pptx
PDF
null (2) bgfbg bfgb bfgb fbfg bfbgf b.pdf
PDF
737-MAX_SRG.pdf student reference guides
PDF
Mitigating Risks through Effective Management for Enhancing Organizational Pe...
PPTX
Sustainable Sites - Green Building Construction
PPTX
additive manufacturing of ss316l using mig welding
PPT
Mechanical Engineering MATERIALS Selection
PDF
Automation-in-Manufacturing-Chapter-Introduction.pdf
PDF
Enhancing Cyber Defense Against Zero-Day Attacks using Ensemble Neural Networks
Embodied AI: Ushering in the Next Era of Intelligent Systems
III.4.1.2_The_Space_Environment.p pdffdf
FINAL REVIEW FOR COPD DIANOSIS FOR PULMONARY DISEASE.pptx
R24 SURVEYING LAB MANUAL for civil enggi
BIO-INSPIRED HORMONAL MODULATION AND ADAPTIVE ORCHESTRATION IN S-AI-GPT
6ME3A-Unit-II-Sensors and Actuators_Handouts.pptx
Introduction, IoT Design Methodology, Case Study on IoT System for Weather Mo...
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
Human-AI Collaboration: Balancing Agentic AI and Autonomy in Hybrid Systems
573137875-Attendance-Management-System-original
Engineering Ethics, Safety and Environment [Autosaved] (1).pptx
Construction Project Organization Group 2.pptx
null (2) bgfbg bfgb bfgb fbfg bfbgf b.pdf
737-MAX_SRG.pdf student reference guides
Mitigating Risks through Effective Management for Enhancing Organizational Pe...
Sustainable Sites - Green Building Construction
additive manufacturing of ss316l using mig welding
Mechanical Engineering MATERIALS Selection
Automation-in-Manufacturing-Chapter-Introduction.pdf
Enhancing Cyber Defense Against Zero-Day Attacks using Ensemble Neural Networks
Ad

osy_unit_2.pptxservices and components of OS

  • 1. Chapter 2 Services and Components of Operating System By Ms. H. C Kunwar Lecturer RAISONI GROUP OF INSTITUTIONS RAISONI GROUP OF INSTITUTIONS
  • 2. RAISONI GROUP OF INSTITUTIONS Operating System Services • Operating systems provide an environment for execution of programs and services to programs and users 1. User interface : - Almost all operating systems have a user interface (UI) Varies between Command-Line (CLI), Graphics User Interface (GUI), Batch 2. 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). 3. I/O operations : - A running program may require I/O, which may involve a file or an I/O device 4. File-system manipulation :- The file system is of particular interest. Programs need to read and write files and directories, create and delete them, search them, list file Information, permission management.
  • 3. RAISONI GROUP OF INSTITUTIONS Operating System Services (Cont.) 5. Communications :– Processes may exchange information, on the same computer or between computers over a network Communications may be via shared memory or through message passing (packets moved by the OS) 6. Error detection :– OS needs to be constantly aware of possible errors • May occur in the CPU and memory hardware, in I/O devices, in user program • For each type of error, OS should take the appropriate action to ensure correct and consistent computing • Debugging facilities can greatly enhance the user’s and programmer’s abilities to efficiently use the system
  • 4. RAISONI GROUP OF INSTITUTIONS Operating System Services (Cont.) 6. Resource allocation :- When multiple users or multiple jobs running concurrently, resources must be allocated to each of them Many types of resources - Some (such as CPU cycles, main memory, and file storage) may have special allocation code, others (such as I/O devices) may have general request and release code 7. Accounting :- To keep track of which users use how much and what kinds of computer resources 8. Protection and security:- The owners of information stored in a multiuser or networked computer system may want to control use of that information, concurrent processes should not interfere with each other • Protection involves ensuring that all access to system resources is controlled • Security of the system from outsiders requires user authentication, extends to defending external I/O devices from invalid access attempts
  • 5. RAISONI GROUP OF INSTITUTIONS A View of Operating System Services
  • 6. RAISONI GROUP OF INSTITUTIONS System Calls • System call is an interface between a running program and operating system. It allows user to access services provided by operating system. This system calls are procedures written using C,C++ and assembly language instructions. • The interface between a process and an operating system is provided by system calls. • Each operating system has its own name for each system call. • Each system call is associated with a number that identifies itself • System calls are usually made when a process in user mode requires access to a resource. Then it requests the kernel to provide the resource via a system call.
  • 7. RAISONI GROUP OF INSTITUTIONS System Call Implementation • Typically, a number associated with each system call System-call interface maintains a table indexed according to these numbers. • The system call interface invokes intended system call in OS kernel and returns status of the system call and any return values. • The caller need know nothing about how the system call is implemented • Just needs to obey API and understand what OS will do as a result call. • Most details of OS interface hidden from programmer by API.
  • 8. RAISONI GROUP OF INSTITUTIONS How System Call Implemented
  • 9. RAISONI GROUP OF INSTITUTIONS Types of System Calls • Process control – end, abort – load, execute – create process, terminate process – get process attributes, set process attributes – wait for time – wait event, signal event – allocate and free memory • File management – create file, delete file – open, close file – read, write, reposition – get and set file attributes
  • 10. RAISONI GROUP OF INSTITUTIONS Types of System Calls (Cont.) • Device management – request device, release device – read, write, reposition – get device attributes, set device attributes – logically attach or detach devices • Information maintenance – get time or date, set time or date – get system data, set system data – get and set process, file, or device attributes • Communications – create, delete communication connection – send, receive messages – transfer status information – attach and detach remote devices
  • 11. RAISONI GROUP OF INSTITUTIONS Examples of Windows and Unix System Calls
  • 12. RAISONI GROUP OF INSTITUTIONS Operating System Components • Process Management • Main Memory Management • Secondary-Storage Management • I/O System Management • File Management
  • 13. RAISONI GROUP OF INSTITUTIONS Process Management • A process is a program in execution. A process needs certain resources, including CPU time, memory, files, and I/O devices, to accomplish its task. • The operating system is responsible for the following activities in connection with process management. – Process creation and deletion. – process suspension and resumption. – Provision of mechanisms for: • process synchronization • process communication
  • 14. RAISONI GROUP OF INSTITUTIONS Main-Memory Management • Memory is a large array of words or bytes, each with its own address. It is a repository of quickly accessible data shared by the CPU and I/O devices. • Main memory is a volatile storage device. It loses its contents in the case of system failure. • The operating system is responsible for the following activities in connections with memory management: – Keep track of which parts of memory are currently being used and by whom. – Decide which processes to load when memory space becomes available. – Allocate and deallocate memory space as needed.
  • 15. RAISONI GROUP OF INSTITUTIONS Secondary-Storage Management • Since main memory (primary storage) is volatile and too small to accommodate all data and programs permanently, the computer system must provide secondary storage to back up main memory. • Most modern computer systems use disks as the principle on-line storage medium, for both programs and data. • The operating system is responsible for the following activities in connection with disk management: – Free space management – Storage allocation – Disk scheduling
  • 16. RAISONI GROUP OF INSTITUTIONS I/O System Management • The I/O system consists of: – A buffer-caching system – A general device-driver interface – Drivers for specific hardware devices
  • 17. RAISONI GROUP OF INSTITUTIONS File Management • A file is a collection of related information defined by its creator. Commonly, files represent programs (both source and object forms) and data. • The operating system is responsible for the following activities in connections with file management: – File creation and deletion. – Directory creation and deletion. – Support of primitives for manipulating files and directories. – Mapping files onto secondary storage. – File backup on stable (nonvolatile) storage media.
  • 18. RAISONI GROUP OF INSTITUTIONS Use of Operating System Tools Following are the operating tools:  User Management  Security policy  Device Management  Performance Monitor  Task Scheduler
  • 19. RAISONI GROUP OF INSTITUTIONS Use of Operating System Tools(cont..) 1. User Management: • User management includes everything from creating a user to deleting a user on your system. User management can be done in three ways on a Linux system. • Command line tools include commands like useradd, userdel, usermod, passwd, etc. These are mostly used by the server administrators. • Useradd: With useradd commands you can add a user. • Syntax: useradd -m -d /home/ - c "" • Example: useradd -m -d /home/xyz -c "xyz" xyz
  • 20. RAISONI GROUP OF INSTITUTIONS Use of Operating System Tools(cont..) 2. Device Management: • Device management is the process of managing the implementation, operation and maintenance of a physical and/or virtual device. • All Linux device files are located in the /dev directory, which is an integral part of the root (/) file system because these device files must be available to the operating system during the boot process. • Example: ls –l /dev • Above example gives the list of device file from kernel.
  • 21. RAISONI GROUP OF INSTITUTIONS Use of Operating System Tools(cont..) 3. Performance Monitor: • It is very tough job for every system or network administrator to monitor and debug Linux System Performance problems every day. • The commands discussed below are some of the most fundamental commands when it comes to system analysis and debugging Linux server issues such as: • vmstat: Virtual memory statistics • The vmstat command reports information about processes, memory, paging, block IO, traps, and cpu activity. • Eg. $ vmstat 3
  • 22. RAISONI GROUP OF INSTITUTIONS Use of Operating System Tools(cont..) 3. Security Policy: • Security policies cover all preventative measures and techniques to ensure the safeguarding of an OS, the network it connects to, and the data which can be stolen, edited or deleted. • OS security policies and procedures cover a broad area (i.e. from threats to attacks), there are many ways to address them. • Some of these areas include: • Ensuring systems are patched or updated regularly. • Installing and updating anti-virus software. • Installing a firewall and ensuring it is configured properly to monitor all incoming and outgoing traffic. • Implementing user management procedures secure user accounts and privileges.
  • 23. RAISONI GROUP OF INSTITUTIONS Use of Operating System Tools(cont..) 3. Task Scheduler: • The Task Scheduler is a tool included with Windows that allows predefined actions to be automatically executed whenever a certain set of conditions is met. • For example, you can schedule a task to run a backup script every night, or send you an e-mail whenever a certain system event occurs
  • 24. Thank You End of Chapter 2