1 CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 1.
-
Upload
rita-oconnor -
Category
Documents
-
view
225 -
download
0
Transcript of 1 CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 1.
1
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 1
2
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 2
“ An operating system (OS ) issoftware , consisting of
programs and data, that runs on computers and manages the computer hardware and
provides common services for efficient execution of variou
s application software ”
3
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 3
แนะน��ร�ยวิช�
เน �อห�วิช�ครอบคลุ�มก�รศึ�กษ�บทบ�ทแลุะหน��ท��ของระบบปฏิบ"ติก�รท��ม�ควิ�มสำ��ค"ญติ&อระบบคอมพิวิเติอร( องค(ประกอบของระบบ
ปฏิบ"ติก�ร ก�รจั"ดก�รโพิรเซสำ ก�รจั"ดก�รหน&วิยควิ�มจั�� ก�รจั"ดก�รระบบแฟ้.มข�อม/ลุ ก�รจั"ดก�รอ�ปกรณ์(อนพิ�ติแลุะเอ�ท(พิ�ติ ก�รควิบค�มก�รเข��ถึ�งข�อม/ลุ รวิมท"�งระบบปฏิบ"ติ
ก�รสำ��หร"บเคร อข&�ย แลุะระบบปฏิบ"ติก�รสำ��หร"บระบบม"ลุติโพิรเซสำเซอร(
4
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 4
ข้�อตกลงในชั้� นเรี�ยน• เวิลุ�เข��เร�ยนไม&ติ���กวิ&�ร�อยลุะ 80
– ข�ดได�ไม&เกน 3 คร"�ง – ม�สำ�ยกวิ&�เวิลุ�เร�ยนคร��งช"�วิโมง 2 คร"�ง ถึ อวิ&�ข�ด 1 คร"�ง
• สำ&งง�นท��ได�ร"บมอบหม�ยท"�งหมดครบแลุะติรงติ�มระยะเวิลุ�ท��ก��หนด• ก�รแติ&งก�ย ให�เป4นไปติ�มระเบ�ยบมห�วิทย�ลุ"ยก��หนด ห�กฝ่6�ฝ่7นจัะไม&ได�ร"บอน�ญ�ติให�เข��ช"�นเร�ยน
5
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 5
ข�อติกลุงในก�รก��หนดคะแนน•ระหวิ&�งภ�ค 50( %) แบ&งเป4น –ควิ�มสำนใจั (ก�รเข��เร�ยน จัรยธรรม แลุะ ก�รแติ&งก�ย )1 0 %–ง�นท��ได�ร"บมอบหม�ย 20%–สำอบกลุ�งภ�ค 30%
•ปลุ�ยภ�ค 50%) –สำอบปลุ�ยภ�ค 50%
6
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 6
หน�งสื�อที่��ใชั้�ในการีที่บที่วน• TextBook Operating System 8th Edition Silberschatz (Yale University ), Peter B. Galvin (Corporate Technologies),
Greg Gagne (Westminster College) July 2008, ©2009
• E-Learning htpp//ele.kbu.ac.th/Boonyong
• http://elc.kbu.ac.th/users/index.php
7
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 7
Chapter 1 Introduction
8
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 8
Objectives
• To describes the Operating system. • To describes each Componets of an Operating System.
• To discuss Development of an Operating System.
• To explain the Operation of Different type of
Operating System.
9
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 9
Topic Covered
• What is an Operating System?• What are the components of an OS?• What does an OS do?• Short History of OSs• Different types of OSs
10
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 10
What is an Operating System?• A program that acts as an intermediary between a user of a computer and the computer hardware.
• Operating system goals:– Execute user programs and make solving user problems easier.
– Make the computer system convenient to use.
• Use the computer hardware in an efficient manner.
11
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 11
Computer System Components1. Hardware – provides basic computing resources (CPU, memory, I/O devices).
2. Operating system – controls and coordinates the use of the hardware among the various application programs for the various users.
3. Applications programs – define the ways in which the system resources are used to solve the computing problems of the users (compilers, database systems, video games, business programs).
4. Users - (people, machines, other computers).
12
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 12
Abstract View of System Components
13
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 13
System Components
• The operating system run in kernel or supervisor mode - protected from user tampering
• Compilers, editors and application programs run in user mode
Instruction Set Architecture
Physical devices grouped together to form functional units
Integrated circuit chips, power supply, CRT
Hides the complexity of machine language from programmer
14
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 14
Functions of an OS• User Environment - OS layer transforms bare hardware machine into higher level abstractions– Execution environment - process management, file manipulation, interrupt handling, I/O operations, language.
– Error detection and handling– Protection and security– Fault tolerance and failure recovery
15
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 15
Functions of an OS• Resource Management
– Time management•CPU and disk transfer scheduling
– Space management •main and secondary storage allocation
– Synchronization and deadlock handling•IPC, critical section, coordination
– Accounting and status information•resource usage tracking
16
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 16
History of Operating Systems• Pre-electronic
– Charles Babbage (1792-1871) “analytical machine”
– Purely mechanical, failed because technology could not produce the required wheels, cog, gears to the required precision
• First generation 1945 - 1955– Aiken, von Neumann, Eckert, Mauchley and Zuse– programming done via plugboards, no OS or language
– vacuum tubes
17
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 17
History of Operating Systems
• Second generation 1955 - 1965– transistors more reliable than vacuum tubes– jobs read in via punched cards– batch systems introduced to reduce wasted time in setting up and running jobs
•bring cards to 1401•read cards to tape offline•put tape on 7094 which does computing•put tape on 1401 which prints output offline
18
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 18
History of Operating Systems• Third generation 1965 – 1980
– IBM System/360: combine business and scientific computers into one machine
– Computer will grow with client(memory, processor speed, number of I/O devices etc.)
– Forerunner of 370, 4300, 3080 and 3090– Use of integrated circuits provided major price/performance
advantage over 2nd generation– OS/360 had to meet conflicting needs which resulted in
enormous and complex operating system– Introduced multiprogramming to make most efficient use of CPU
– Spooling: read jobs from cards to disk ready to load into memory and queue output to disk for printing
19
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 19
History of Operating Systems
• In batch, total time from submitting a job to getting the output was a few hours, very unproductive for programmers
• Timesharing (a variant of multiprogramming) provides for user interaction with the computer system– On-line communication between the user and the system is
provided; when the operating system finishes the execution of one command, it seeks the next “control statement” from the user’s keyboard.
– The CPU is multiplexed among several jobs that are kept in memory and on disk (the CPU is allocated to a job only if the job is in memory).• takes advantage of the idle CPU • switch occurs so frequently that the user can interact with each program as it
is running• each command is short so only a little CPU time is needed for each user• each user is given the impression that the entire system is dedicated to his
use• Batch jobs could be running in background• CTSS (Compatible Time Sharing System - MIT) was first success
• Minicomputers and the development of UNIX– UNIX was stripped down, one user version of MULTICS (extension of CTSS)– Numerous variants : System V, BSD, POSIX (IEEE), MINIX, Linux
20
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 20
History of Operating Systems• Fourth generation 1980 – present
– Large Scale Integrated chips– personal computers– 1974: Intel developed 8080 chip (8 bit CPU), Gary Kildall wrote
CP/M OS (Intel gave him the rights) and formed Digital Research– Early 1980s: IBM designed IBM PC. Bill Gates had BASIC
interpreter and recommended DR as an OS. Kildall sent subordinate to meeting and refused to sign non-disclosure. Gates was asked for an OS, bought DOS from Seattle Computer Products and offered IBM DOS/BASIC package. Renamed it MS -DOS
– Early Windows versions ran on top of DOS, Windows 95 and beyond and NT were full fledged OSs
– Network Operating Systems (user sees multiple computers)– Distributed Operating Systems (user sees one processor)
21
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 21
Mainframe Systems• First computers used to solve many commercial and scientific applications– evolved from batch time shared systems
• Reduce setup time by batching similar jobs– serial card readers were initial input device then disks enabled job scheduling by the operating system
• Automatic job sequencing – automatically transfers control from one job to another. – first rudimentary operating system.– CPU often idle because of great differences in speed between mechanical I/O vs. electronic devices
• Early OS called resident monitor– initial control in monitor – control transfers to job – when job completes control transfers pack to monitor– eliminated intervention by programmer
22
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 22
Memory Layout for a Simple Batch System
23
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 23
Multiprogrammed Batch Systems
Several jobs from the pool of all submitted jobs are kept in main memory at the same time, and the CPU is multiplexed among them.
24
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 24
OS Features Needed for Multiprogramming
• Why multiprogramming?– Increases CPU utilization by trying to always keep the CPU busy processing some job
– I/O of one job causes switch to another job
• Memory management – the system must allocate the memory to several jobs.
• CPU scheduling – the system must choose among several jobs ready to run.
• Allocation of devices.
25
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 25
Desktop Systems
• Personal computers – computer system dedicated to a single user.
• I/O devices – keyboards, mice, display screens, small printers.
• User convenience and responsiveness.• Can adopt technology developed for larger operating systems. Often individuals have sole use of computer and do not need advanced CPU utilization of protection features.
• May run several different types of operating systems (Windows, MacOS, UNIX, Linux)
26
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 26
Parallel Systems• Multiprocessor systems with more than on CPU in close communication.
• Tightly coupled system – processors share memory and a clock; communication usually takes place through the shared memory.
• Advantages of parallel system: – Increased throughput with more processors– Economical – share peripherals, mass storage, power etc. as opposed to individual PCs
– Increased reliability•graceful degradation / fault tolerant
– failure of one processor will slow down but not halt the system
– other processors pick up the slack
27
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 27
Parallel Systems (Cont.)• Symmetric multiprocessing (SMP)– Each processor runs and identical copy of the operating system.
– Many processes can run at once without performance deterioration.
– Most modern operating systems support SMP
• Asymmetric multiprocessing– Each processor is assigned a specific task; controlling processor schedules and allocates work to other processors.
– More common in extremely large systems
28
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 28
Distributed Systems• Distribute the computation among several physical processors.
• Loosely coupled system – each processor has its own local memory; processors communicate with one another through various communications lines, such as high-speed buses or telephone lines.
• Advantages of distributed systems.– Resource sharing – Computation speed up – load sharing – Reliability– Communications between processors and processes
29
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 29
Distributed Systems (cont)
• Requires networking infrastructure.– TCP/IP is the most common network protocol
• Local area networks (LAN) or Wide area networks (WAN)
• May be either client-server or peer-to-peer systems.
30
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 30
Real-Time Systems• Often used as a control device in a dedicated application such as controlling scientific experiments, medical imaging systems, industrial control systems, and some display systems.
• Well-defined, fixed time constraints.• Hard real-time:
– Secondary storage limited or absent, data stored in short term memory, or read-only memory (ROM)
– Not supported by general-purpose operating systems.
• Soft real-time– Limited utility in industrial control of robotics– Useful in applications (multimedia, virtual reality) requiring advanced operating-system features.
31
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 31
Handheld Systems• Personal Digital Assistants (PDAs)• Cellular telephones• Issues:
– Limited memory (512KB to 8MB) requires efficient management
– Slow processors– Small display screens.
32
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 32
Migration of Operating-System Concepts and Features
33
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 33
Assignment (1)
• BOOTABLE DISK• BOOTABLE CD• BOOTABLE FLASH DRIVE
34
CS.217 Operating System By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 1 Introduction Slide 34
Assignment (2)UNIX,MAC,SOLARY,SYMBIAN Operating System• - History• - Design Principles• - System Components• - Environmental Subsystems • - File system• - Networking• - Programmer Interface
The Linux Operating System• - History • - Design Principles• - Kernel Modules• - Process Management• - Scheduling • - Memory Management • - File Systems• - Input and Output • - Intercrosses Communication• - Network Structure
Windows Operating System• - History• - Design Principles• - System Components• - Environmental Subsystems • - File system• - Networking• - Programmer Interface