Download presentation
Presentation is loading. Please wait.
Published byMadeleine Shelton Modified over 9 years ago
1
Chapter 6-- Operating Systems Overview Chapter 6 OPERATING SYSTEMS OVERVIEW 1
2
Chapter 6-- Operating Systems Overview WHAT IS AN OPERATING SYSTEM? An interface between users and machine(hardware,software) - an environment "architecture” Allows convenient usage; hides the tedious stuff Allows efficient usage; parallel activity, avoids wasted cycles Provides information protection Gives each user a slice of the resources Acts as a control program. 2
3
Chapter 6-- Operating Systems Overview OPERATING SYSTEM OVERVIEW The Layers Of A System Program Interface Humans User Programs O.S. Interface O.S. Hardware Interface/ Privileged Instructio ns Disk/Tape/Memory 3
4
Chapter 6-- Operating Systems Overview Other Characteristics include: Time Sharing - multiprogramming environment that's also interactive. Multiprocessing - Tightly coupled systems that communicate via shared memory. Used for scientific applications. Used for speed improvement by putting together a number of off-the-shelf processors. Distributed Systems - Loosely coupled systems that communicate via message passing. Advantages include resource sharing, speed up, reliability, communication. Real Time Systems - Rapid response time is main characteristic. Used in control of applications where rapid response to a stimulus is essential. Characteristics 4
5
Chapter 6-- Operating Systems Overview Characteristics contd…. Interrupts: Interrupt transfers control to the interrupt service routine generally, through the interrupt vector, which contains the addresses of all the service routines. Interrupt architecture must save the address of the interrupted instruction. Incoming interrupts are disabled while another interrupt is being processed to prevent a lost interrupt. A trap is a software-generated interrupt caused either by an error or a user request. An operating system is interrupt driven. 5
6
Chapter 6-- Operating Systems Overview Very fast storage is very expensive. So the Operating System manages a hierarchy of storage devices in order to make the best use of resources. In fact, considerable effort goes into this suppor t. Storage Hierarchy Fast and Expensive Slow an Cheap 6
7
Chapter 6-- Operating Systems Overview The goal is protecting the Operating System and others from malicious or ignorant users. The User/Supervisor Mode and privileged instructions. Concurrent threads might interfere with others. This leads to protection of resources by user/supervisor mode. These resources include: I/O Define I/O instructions as privileged; they can be executed only in Supervisor mode. System calls get us from user to supervisor mode. Protection 7
8
Chapter 6-- Operating Systems Overview Memory A user program can only access its own logical memory. For instance, it can't modify supervisor code. Depends on an address translation scheme such as that shown here. Protection 8
9
Chapter 6-- Operating Systems Overview CPU A clock prevents programs from using all the CPU time. This clock causes an interrupt that causes the operating system to gain control from a user program. Protection For machines connected together, this protection must extend across: Shared resources, Multiprocessor Architectures, Clustered Systems The practice of this is called “distributed operating systems”. 9
10
Resource Management Resource Management in DS is concerned with making both local and remote resources available to the user. Resource Management is roughly divided into three areas: The program, i.e., the location of the computation, must be able to access data. These data is generally thought of as being contained in a file that is referenced (open, read, write, modify, etc) by the program. Hence, one of the issues in data migration is the design of a file system that hides the location of the data with respect to the location of the program. Network Transparency 1.Data Migration 2. Computation Migration 3. Distributed Scheduling Chapter 6-- Operating Systems Overview10
11
Resource Management cont’d Another issue in Data Migration is shared memory access among multiple computers. Distribute Shared Memory (SHMEM) must guarantee that the consistency of data is maintained. Think about how SHMEM could be implemented !! 1. How should can we achieve network transparency? 1. How can we manage memory across all computers? 2. Computation Migration: Here, the computation “moves” to another location, where the data may be available. Paradigms for computation migration include: 1. Remote Procedure Calls (RPC) 2. Mobile Agents (MA) 3. Process Migration Chapter 6-- Operating Systems Overview11
12
Resource Management cont’d The fact that jobs (or processes) may be transferred to remote machines requires a distributed scheduling strategy. Distributed Scheduling must assure that the resources of the entire systems are utilized optimally and must assure that specific job requirements are being met. This is of even greater importance in GRID computing environments where resources are generally owned and operated by different organizations. Issues related to distributed scheduling include: 1. Load Balancing 2. Resource Utilization 3. Quality of Service (for Jobs) 4. Cost / Performance Tradeoff 5. Security (maybe) Chapter 6-- Operating Systems Overview12
13
Networks and Communication Any DS is build on top of some type of Communication Infrastructure. Remote hosts are connected to sub- networks via switches. Subnets connect to other subnets or a backbone via routers. We can distinguish different types of networks / network classes: 1. Wide Area Networks 2. Local Area Networks 3. Metropolitan Area Networks 4. Wireless (not really a nw-class) 5. Ad-Hoc ( not really a nw-class) Chapter 6-- Operating Systems Overview13
14
Main Network Types Local Area Networks (LANs) 1. Processors distributed over small geographical areas, e.g. single building, or neighboring buildings 2. Replacement of large mainframe computer systems 3. High speed, reliability and quality (usually more expensive high quality cables are used) Wide Area Networks (WANs) 1. Autonomous processors distributed over large geographical area, e.g. the U.S. 2. Originally as an academic project to provide communication between sites. 3. First WAN: Arpanet 4. Examples: Internet, inter- connection of company sites 5. Subject to slower unreliable channels Chapter 6-- Operating Systems Overview14
15
DS and Networks A DS may span as little as a small LAN or as much as multiple WANs. Different Topologies may determine the structure of algorithms used to facilitate a DS. 1. Ring Topology 2. Star Topology 3. Tree Topology 4. Bus Topology 5. Switched subnets The concept of topology may be extended beyond the physical layer into the logical structure of the DS. This structure may be exploited in formulating more efficient communication sequences. In this course, we will mostly disregard the specific structure of the network and make some simplifying assumption on reliability of the underlying communication. Chapter 6-- Operating Systems Overview15
16
Communication Naming and Name Resolution Host name must be unique within network. Domain Name System (DNS) Name-to-address resolution Hierarchical system of name servers Before: all hosts needed to know all addresses Routing 1. Fixed routing: fixed communication path 2. Virtual routing: fixed for session 3. Dynamic routing: use of packets; can take link load into account Quality of Service (QoS) 1. Loss 2. Latency Chapter 6-- Operating Systems Overview16
17
Communication contd Packet Strategies 1. Fixed length messages: packets, frames, datagrams 2. Connectionless unreliable service vs reliable service Connection Strategies 1. Circuit switching: permanent physical link for session 2. Message switching: temporary link for message 3. Packet switching Contention Collisions may occur on network CSMA/CD Carrier Sense with Multiple Access: check if link is free Collision Detection: stop transmitting, wait for random time interval Token passing Usually in ring structure Node with token may transmit Message slots Fixed length message slots are passed (often in ring ) Chapter 6-- Operating Systems Overview17
18
Communication Protocols Modes of communication 1. Asynchronous 1. Large overhead 2. Synchronous 1. Set-up phase 2. Negotiate communication parameters 3. Connectionless User Datagram Protocrol (UDP) 4. Connection-oriented Transmission Control Protocol/Internet Protocol (TCP/IP) International Standards Organization (OSI) layers 1. Physical layer: mechanical and electrical details 2. Data-link layer: handle frames, error detection and recovery 3. Network layer: provide connections, routing 4. Transport layer: Transfer messages between clients, packet order, etc. 5. Session layer: Process-to process communication 6. Presentation layer: Formats, character conversion, etc Chapter 6-- Operating Systems Overview18
19
Communication Primitives Unless the network architecture provides functions to access the lower layers of the protocol stack, communication primitives are used at the application layer. Most DS algorithms and protocols assume only 2 primitives: 1. SEND message 2. RECEIVE message We need to distinguish, however, two modes of primitives: 1. Synchronous 2. Asynchronous application transport network data link physical application transport network data link physical application transport network data link physical Chapter 6-- Operating Systems Overview19
20
Communication Primitives In synchronous communication, a SEND is blocked until a corresponding RECEIVE is executed on the remote machine (or process). With asynchronous communication, a SEND operation is buffered and the process is not blocked to wait for a corresponding receive. RPC One frequently used communication vehicle in DS is the Remote Procedure Call RPC provides access to functionality that is available on remote hosts. In the program, the RPC is “identical” to a local procedure call. The fact that the procedure is actually executed remotely is hidden. Chapter 6-- Operating Systems Overview20
21
Robustness Failure Detection 1. Hard to distinguish type of failure in DS 1. Link failure 2. Site failure 3. Message loss 2. Handshaking procedure sending “I-am-up” and “Are- you-up?” messages 1. Combine with time-out scheme Reconfiguration Assume failure has been discovered Link failure: broadcast information Assumed site failure, notify every site in DS Possibly elect new coordinator site What if site did not really fail? Recovery 1. Notify that link is back up 2. Notify that site back up Chapter 6-- Operating Systems Overview21
22
References www.web.cs.wpi.edu/~jb/CS502/lectures (for operating system) www.cse.unt.edu/~mikler/Courses/OS/Slides (for Resource management) Chapter 6-- Operating Systems Overview22
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.