Operating Systems: Internals and Design Principles, 6/E           William Stallings        Chapter 2Operating System Overv...
Operating System• A program that controls the execution of  application programs• An interface between applications and  h...
Operating System Objectives• Convenience: make the computer more  convenient to use• Efficiency: in using the system resou...
Layers and Views
Services Provided by the OS• Program development    – Editors and debuggers•   Program execution•   Access I/O devices•   ...
Services Provided by the OS• Error detection and response  – Internal and external hardware errors  – Software errors  – O...
Services Provided by the OS• Accounting  – Collect usage statistics  – Monitor performance  – Used to anticipate future en...
Operating System• Responsible for managing resources• Functions same way as ordinary computer  software  – It is a program...
OS as Resource Manager
Kernel• Portion of operating system that is in main  memory• Contains most frequently used functions• Also called the nucl...
Evolution of Operating                Systems• Serial processing  – No operating system  – Programs in machine code loaded...
Evolution of Operating                Systems• Serial processing, two main problems:  – Schedule time: waste of time for s...
Evolution of Operating                Systems• Simple batch system: the first OS (batch  OS) on IBM 701 by general Motors ...
Desirable Hardware Features• Memory protection  – Does not allow the memory area containing    the monitor to be altered• ...
Desirable Hardware Features• Privileged instructions  – Certain machine level instructions can only be    executed by the ...
Memory Protection• User program executes in user mode  – Certain instructions may not be executed  – Certain area’s of mem...
Memory Protection• Monitor executes in system mode(Kernel  mode)  – Privileged instructions are executed  – Protected area...
System Utilization Example
Uniprogramming• Processor must wait for I/O instruction to  complete before proceeding
Multiprogramming• When one job needs to wait for I/O, the  processor can switch to the other job
Multiprogramming
Utilization Histograms
Example
Time Sharing Systems• Using multiprogramming to handle multiple  interactive jobs• Processor’s time is shared among multip...
Major AchievementsThere have been five major theoretical advancesin the development of operating systems:•   Processes•   ...
Process• A program in execution• An instance of a program running on a  computer• The entity that can be assigned to and  ...
Process• Consists of three components  – An executable program  – Associated data needed by the program  – Execution conte...
Process
Memory ManagementThe os has five principle storage managementresponsibilities:•   Process isolation•   Automatic allocatio...
Information Protection and             SecurityWork in security and protection can be  grouped into four categories:• Avai...
Information Protection and             Security• Data integrity  – Protection of data from unauthorized    modification• A...
Scheduling and Resource          ManagementAny resource allocation and scheduling policy must  consider three factors:• Fa...
System Structure• View the system as a series of levels• Each level performs a related subset of  functions• Each level re...
Levels• Level 1  – Electronic circuits  – Objects are registers, memory cells, and logic    gates  – Operations are cleari...
Levels• Level 3  – Adds the concept of a procedure or    subroutine, plus call/return operations• Level 4  – Interrupts
Concepts Related to         Multiprogramming• Level 5  – Process as a program in execution  – Suspend and resume processes...
ConceptsRelated to         Multiprogramming• Level 7  – Creates logical address space for processes  – Organizes virtual a...
Deal with External Objects• Level 8  – Communication of information and messages    between processes• Level 9  – Supports...
Deal with External Objects• Level 11  – Responsible for maintaining the association    between the external and internal i...
Upcoming SlideShare
Loading in …5
×

Lec # 1 chapter 2

632 views
501 views

Published on

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
632
On SlideShare
0
From Embeds
0
Number of Embeds
2
Actions
Shares
0
Downloads
0
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Lec # 1 chapter 2

  1. 1. Operating Systems: Internals and Design Principles, 6/E William Stallings Chapter 2Operating System Overview Patricia Roy Manatee Community College, Venice, FL ©2008, Prentice Hall
  2. 2. Operating System• A program that controls the execution of application programs• An interface between applications and hardware
  3. 3. Operating System Objectives• Convenience: make the computer more convenient to use• Efficiency: in using the system resources• Ability to evolve: to permit the effective development, testing, and introduction of new system functions.
  4. 4. Layers and Views
  5. 5. Services Provided by the OS• Program development – Editors and debuggers• Program execution• Access I/O devices• Controlled access to files• System access
  6. 6. Services Provided by the OS• Error detection and response – Internal and external hardware errors – Software errors – OS provide a response that clears the error (ending the program that cause error, retry the operation, or simply reporting the error to the application).
  7. 7. Services Provided by the OS• Accounting – Collect usage statistics – Monitor performance – Used to anticipate future enhancements – Used for billing purposes
  8. 8. Operating System• Responsible for managing resources• Functions same way as ordinary computer software – It is a program that is executed• Operating system relinquishes control of the processor
  9. 9. OS as Resource Manager
  10. 10. Kernel• Portion of operating system that is in main memory• Contains most frequently used functions• Also called the nucleus
  11. 11. Evolution of Operating Systems• Serial processing – No operating system – Programs in machine code loaded from input device – If an error halted the program, the error condition was indicated by lights. – The output appears on the printer
  12. 12. Evolution of Operating Systems• Serial processing, two main problems: – Schedule time: waste of time for short programs. Problem if not finish in the allocated time – Setup time: included loading the compiler, source program, saving compiled program, and loading and linking
  13. 13. Evolution of Operating Systems• Simple batch system: the first OS (batch OS) on IBM 701 by general Motors – Monitor • Software that controls the sequence of events • Batch jobs together • Program returns control to monitor when finished, then the monitor automatically begin loading the next program.
  14. 14. Desirable Hardware Features• Memory protection – Does not allow the memory area containing the monitor to be altered• Timer – Prevents a job from monopolizing the system – If the timer expires the user program stopped.
  15. 15. Desirable Hardware Features• Privileged instructions – Certain machine level instructions can only be executed by the monitor such as I/O instr.• Interrupts – Early computer models did not have this capability. This feature gives the OS the flexibility in relinquishing control and regaining control to and regaining control from user programs.
  16. 16. Memory Protection• User program executes in user mode – Certain instructions may not be executed – Certain area’s of memory are protected from user’s use.
  17. 17. Memory Protection• Monitor executes in system mode(Kernel mode) – Privileged instructions are executed – Protected areas of memory may be accessed
  18. 18. System Utilization Example
  19. 19. Uniprogramming• Processor must wait for I/O instruction to complete before proceeding
  20. 20. Multiprogramming• When one job needs to wait for I/O, the processor can switch to the other job
  21. 21. Multiprogramming
  22. 22. Utilization Histograms
  23. 23. Example
  24. 24. Time Sharing Systems• Using multiprogramming to handle multiple interactive jobs• Processor’s time is shared among multiple users• Multiple users simultaneously access the system through terminals, with the OS interleaving the execution of each user program in a short burst or quantum of computation.
  25. 25. Major AchievementsThere have been five major theoretical advancesin the development of operating systems:• Processes• Memory management• Information protection and security• Scheduling and resource management• System structure
  26. 26. Process• A program in execution• An instance of a program running on a computer• The entity that can be assigned to and executed on a processor
  27. 27. Process• Consists of three components – An executable program – Associated data needed by the program – Execution context of the program • All information the operating system needs to manage the process
  28. 28. Process
  29. 29. Memory ManagementThe os has five principle storage managementresponsibilities:• Process isolation• Automatic allocation and management• Support of modular programming• Protection and access control• Long-term storage
  30. 30. Information Protection and SecurityWork in security and protection can be grouped into four categories:• Availability – Concerned with protecting the system against interruption• Confidentiality – Assuring that users cannot read data for which access is unauthorized
  31. 31. Information Protection and Security• Data integrity – Protection of data from unauthorized modification• Authenticity – Concerned with the proper verification of the identity of users and the validity of messages or data
  32. 32. Scheduling and Resource ManagementAny resource allocation and scheduling policy must consider three factors:• Fairness – Give equal and fair access to resources• Differential responsiveness – Discriminate among different classes of jobs• Efficiency – Maximize throughput, minimize response time, and accommodate as many uses as possible
  33. 33. System Structure• View the system as a series of levels• Each level performs a related subset of functions• Each level relies on the next lower level to perform more primitive functions• This decomposes a problem into a number of more manageable subproblems
  34. 34. Levels• Level 1 – Electronic circuits – Objects are registers, memory cells, and logic gates – Operations are clearing a register or reading a memory location• Level 2 – Processor’s instruction set – Operations such as add, subtract, load, and store
  35. 35. Levels• Level 3 – Adds the concept of a procedure or subroutine, plus call/return operations• Level 4 – Interrupts
  36. 36. Concepts Related to Multiprogramming• Level 5 – Process as a program in execution – Suspend and resume processes• Level 6 – Secondary storage devices – Transfer of blocks of data
  37. 37. ConceptsRelated to Multiprogramming• Level 7 – Creates logical address space for processes – Organizes virtual address space into blocks
  38. 38. Deal with External Objects• Level 8 – Communication of information and messages between processes• Level 9 – Supports long-term storage of named files• Level 10 – Provides access to external devices using standardized interfaces
  39. 39. Deal with External Objects• Level 11 – Responsible for maintaining the association between the external and internal identifiers• Level 12 – Provides full-featured facility for the support of processes• Level 13 – Provides an interface to the OS for the user

×