Lecture01 Os 13fall

download Lecture01 Os 13fall

of 20

Transcript of Lecture01 Os 13fall

  • 8/10/2019 Lecture01 Os 13fall

    1/20

    When we start?

    10/24/2013 Operating Systems, Beykent University 1

  • 8/10/2019 Lecture01 Os 13fall

    2/20

    Early Systems

    10/24/2013 Operating Systems, Beykent University 2

  • 8/10/2019 Lecture01 Os 13fall

    3/20

    Second Generation

    10/24/2013 Operating Systems, Beykent University 3

  • 8/10/2019 Lecture01 Os 13fall

    4/20

    Third Generation

    10/24/2013 Operating Systems, Beykent University 4

  • 8/10/2019 Lecture01 Os 13fall

    5/20

    MULTICS

    10/24/2013 Operating Systems, Beykent University 5

  • 8/10/2019 Lecture01 Os 13fall

    6/20

    Fourth Generation ...

    Personal computers and workstations

    MS-DOS , Linux, Windows NT

    Massively parallel systems Pipelining

    Array processing / SIMD General multiprocessing / MIMD

    Symmetric multiprocessing / SMP

    Computer networks (communication aspect)networkoperating systems

    Distributed computingdistributed operating systems

    Cluster computing, grid computing, etc.

    Mobile computing (mobile operating systems)

    10/24/2013 Operating Systems, Beykent University 6

  • 8/10/2019 Lecture01 Os 13fall

    7/20

    Modern classification based on use

    Low-end consumer desktop Assumes no intelligence on part of the user

    Focuses on hardware and software compatibility

    High-end desktop User is smart but may not be very computer savvy

    Must provide good performance for applications, such as CAD/CAM

    Provide hardware and software compatibility Real-time systems

    User is professional programmer

    Focus on performance, defined response time, easy extendable hardware support, andprogramming control

    Embedded systems Closed box system to do specific functions well

    No expansion slots (standard machine has multiple standard interfaces) Limited applications

    Turn it on and use it (standard host enables all components, scans every interface, and is readyto run multiple apps)

    10/24/2013 Operating Systems, Beykent University 7

  • 8/10/2019 Lecture01 Os 13fall

    8/20

    Where is Operating System?

    10/24/2013 8Operating Systems, Beykent University

    ABSTRACTION

    - Simple, easier to use

    interface (machine-

    independent)

    - Hiding of unnecessary

    details

  • 8/10/2019 Lecture01 Os 13fall

    9/20

    Operating System modes

    10/24/2013 Operating Systems, Beykent University 9

  • 8/10/2019 Lecture01 Os 13fall

    10/20

    Example OS: UNIX

    10/24/2013 Operating Systems, Beykent University 10

    - developed in 1969 by a group of AT&T employees at Bell Labs.

    - was first developed in assembly, but by 1973 almost entirely recoded in C.

  • 8/10/2019 Lecture01 Os 13fall

    11/20

    Two different views of an OS

    Extended machine view

    Virtual machine that is easier to understand andprogram

    Tool to make programmers job easy Resource manager view

    Tool to facilitate efficient operation of computer

    systemProvides services to users; processor, memory,

    I/O, system bus

    10/24/2013 Operating Systems, Beykent University 11

  • 8/10/2019 Lecture01 Os 13fall

    12/20

    Elements of an OS

    Processor/CPU

    Controls the operations of computer and performs data processing functions

    Exchanges data with memory using memory address register and memory bufferregister

    Exchanges data with I/O devices using I/O address register and I/O buffer register

    Main memory/Primary memory

    Stores data and programs

    Typically volatile

    I/O modules

    Moves data between a computer and external environment

    Communicates with a variety of devices including secondary memory (disks),communications equipment, and

    terminals

    System bus

    Provides for communications among processors, main memory, and I/O modules

    10/24/2013 Operating Systems, Beykent University 12

  • 8/10/2019 Lecture01 Os 13fall

    13/20

    OS Main Components

    Process management process creation; deletion; suspension

    process synchronization; communication

    Main-memory management Manage used parts and their current users Select processes to load

    Allocate memory to running processes

    Secondary storage management Free-space management

    Storage allocation

    10/24/2013 Operating Systems, Beykent University 13

  • 8/10/2019 Lecture01 Os 13fall

    14/20

    OS Main Components

    File system management File + directory creation; deletion

    File manipulation primitives

    Mapping files onto secondary storage

    I/o system management general device-driver interface

    Drivers for specific hardware devices

    Protection system Distinguish between authorized and unauthorized

    usage

    Provide means of enforcement

    10/24/2013 Operating Systems, Beykent University 14

  • 8/10/2019 Lecture01 Os 13fall

    15/20

    OS Concepts - Program

    Program

    Collection of instructions and data kept in ordinary

    file on disk

    Executable program, complete code output by

    linker/loader, with input from libraries

    Generated from source program and object code

    The file is marked as executable in the i-node File contents are arranged according to rules

    established by the kernel

    10/24/2013 Operating Systems, Beykent University 15

  • 8/10/2019 Lecture01 Os 13fall

    16/20

    OS Concepts - Process

    Processes Created by kernel as an

    environment in which a programexecutes

    May be stopped and laterrestarted by the OS

    Process may acquire resources(more memory, open files) notpresent in the program

    Process Tree: Child and parentprocesses

    Communication betweenprocesses through messages

    10/24/2013 Operating Systems, Beykent University 16

  • 8/10/2019 Lecture01 Os 13fall

    17/20

    OS Concepts - Threads

    Threads

    Stream of instruction execution; running instanceof a process code

    A dispatchable unit of work to provide intra-process concurrency

    A process may have multiple threads of executionin parallel, each thread executing sequentially

    Threads may execute in time-sharing manner on asingle CPU, on multiple cores concurrently, or onmultiple CPUs

    10/24/2013 Operating Systems, Beykent University 17

  • 8/10/2019 Lecture01 Os 13fall

    18/20

    OS Concepts - Files

    FilesServices of file management system to

    hide disk/tape specifics

    System calls for file management

    Directory to group files together

    Organized as a hierarchical tree

    Root directory

    Path name

    Path name separator

    Working directory

    Protection of files (9-bit code in Unixrwx bits)

    File descriptor or handlesmall integerto identify a file in subsequentoperations, error code to indicate accessdenied

    10/24/2013 Operating Systems, Beykent University 18

    Root directory

    Students

    Gil

    Roni

    Or

    Faculty

    Amnon

    Papers Progs Grants

  • 8/10/2019 Lecture01 Os 13fall

    19/20

    OS ConceptsSystem Calls

    System calls

    Interface between user program and operating system

    Set of extended instructions provided by the

    operating system Applied to various software objects like processes and

    files

    Invoked by user programs to communicate with thekernel and request services

    Broadly divided into six classes:

    filesystem (open), process (fork), scheduling (priocntl), IPC(semop), socket/networking (bind), and miscellaneous (time)

    10/24/2013 Operating Systems, Beykent University 19

  • 8/10/2019 Lecture01 Os 13fall

    20/20

    A System Call

    10/24/2013 Operating Systems, Beykent University 20