CSC 360- Instructor: K. Wu Interfaces to OS Services.

Slides:



Advertisements
Similar presentations
Operating-System Structures
Advertisements

Operating System Structures
Lesson 6. The Computer Operation Computer Operating Systems GUI vs. Command line The Microsoft Windows Family File Systems – How Computers Manage Data.
Slide 2-1 Copyright © 2004 Pearson Education, Inc. Operating Systems: A Modern Perspective, Chapter 2 Using the Operating System 2.
Chap 2 System Structures.
Operating System Structure
Operating-System Structures
UNIX Chapter 01 Overview of Operating Systems Mr. Mohammad A. Smirat.
Chapter 2: Operating-System Structures
1 CS 333 Introduction to Operating Systems Class 2 – OS-Related Hardware & Software The Process Concept Jonathan Walpole Computer Science Portland State.
2: OS Structures 1 Jerry Breecher OPERATING SYSTEMS STRUCTURES.
Advanced OS Chapter 3p2 Sections 3.4 / 3.5. Interrupts These enable software to respond to signals from hardware. The set of instructions to be executed.
Cs238 Lecture 3 Operating System Structures Dr. Alan R. Davis.
1 Operating Systems Ch An Overview. Architecture of Computer Hardware and Systems Software Irv Englander, John Wiley, Bare Bones Computer.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition Chapter 2: Operating-System Structures Modified from the text book.
Process. Process Concept Process – a program in execution Textbook uses the terms job and process almost interchangeably A process includes: – program.
An Introduction to Operating Systems. Definition  An Operating System, or OS, is low-level software that enables a user and higher-level application.
Linux Shell. 2 Linux Command-Line Interface ■ Linux shells: A shell is a command interpreter that allows you to type commands from the keyboard to interact.
User Interfaces Operating Systems Lecture 2, 20 March 2003 Mr. Greg Vogl Uganda Martyrs University.
Week 6 Operating Systems.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Chapter 2: Operating-System Structures.
Rensselaer Polytechnic Institute CSCI-4210 – Operating Systems David Goldschmidt, Ph.D.
Operating System. Architecture of Computer System Hardware Operating System (OS) Programming Language (e.g. PASCAL) Application Programs (e.g. WORD, EXCEL)
OPERATING SYSTEM OVERVIEW. Contents Basic hardware elements.
Silberschatz, Galvin and Gagne ©2013 Operating System Concepts – 9 th Edition Chapter 2: Operating-System Structures.
Chapter 2: Operating-System Structures. 2.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts – 7 th Edition, Jan 14, 2005 Operating System.
OS provide a user-friendly environment and manage resources of the computer system. Operating systems manage: –Processes –Memory –Storage –I/O subsystem.
Chapter 2: Operating-System Structures. 2.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts Chapter 2: Operating-System Structures Operating.
2.1 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts Chapter 2: Operating-System Structures Overview of topics covered Operating System Services.
Silberschatz, Galvin and Gagne  2002 Modified for CSCI 399, Royden, Operating System Concepts Operating Systems Lecture 6 System Calls OS System.
Chapter 2: Linux & POSIX “She sells bash shells by the C shore”
E X C E E D I N G E X P E C T A T I O N S OP SYS Linux System Administration Dr. Hoganson Kennesaw State University Operating Systems Functions of an operating.
Operating Systems David Goldschmidt, Ph.D. Computer Science The College of Saint Rose CIS 432.
CIT 140: Introduction to ITSlide #1 CSC 140: Introduction to IT Operating Systems.
Computers Operating System Essentials. Operating Systems PROGRAM HARDWARE OPERATING SYSTEM.
Systems Software Operating Systems. What is software? Software is the term that we use for all the programs and data that we use with a computer system.
Operating-System Structures. Operating System Services Operating systems provide an environment for execution of programs and services to programs and.
LINUX System : Lecture 7 Bong-Soo Sohn Lecture notes acknowledgement : The design of UNIX Operating System.
Operating Systems Lecture November 2015© Copyright Virtual University of Pakistan 2 Agenda for Today Review of previous lecture Hardware (I/O, memory,
OS, , Part I Operating - System Structures Department of Computer Engineering, PSUWannarat Suntiamorntut.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Chapter 2: Operating-System Structures.
Chapter 2. System Structures
Copyright © Curt Hill Operating Systems An Introductory Overview.
Credit:  An operating system is the program that is loaded into the computer  coordinates all the activities among.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Chapter 2: System Structures.
Major OS Components CS 416: Operating Systems Design, Spring 2001 Department of Computer Science Rutgers University
1 Chapter 2: Operating-System Structures Services Interface provided to users & programmers –System calls (programmer access) –User level access to system.
Operating System Structure Lecture: - Operating System Concepts Lecturer: - Pooja Sharma Computer Science Department, Punjabi University, Patiala.
OPERATING SYSTEMS STRUCTURES Jerry Breecher 2: Operating System Structures 1.
Introduction to Operating Systems Concepts
Chapter 2: Operating-System Structures
Operating Systems {week 01.b}
Chapter 2:Operating System Structures
Exceptional Control Flow
Chapter 2: Operating-System Structures
CASE STUDY 1: Linux and Android
Exceptional Control Flow: System Calls, Page Faults etc.
What is an Operating System?
Chapter 2: Operating-System Structures
Chapter 2: Operating-System Structures
Chapter 2: Operating-System Structures
Chapter 2: System Structures
Mid Term review CSC345.
Operating Systems Lecture 3.
LINUX System : Lecture 7 Lecture notes acknowledgement : The design of UNIX Operating System.
Chapter 2: Operating-System Structures
Chapter 2: Operating-System Structures
CS510 Operating System Foundations
OPERATING SYSTEMS STRUCTURES
Chapter 2: Operating-System Structures
Presentation transcript:

CSC 360- Instructor: K. Wu Interfaces to OS Services

CSC 360- Instructor: K. Wu Agenda 1.OS Services 2.Command Line Interfaces 3. GUI Interfaces 4.System Calls 5.API 6.Unix Manual

CSC 360- Instructor: K. Wu 2 1. OS services (1) User/programmer interfaces –command line, GUI, API, system calls Program execution I/O operation File manipulation Process communication Error handling: software/hardware error

CSC 360- Instructor: K. Wu 3 1. OS services (2) Resource allocation and arbitration –CPU, memory, storage, I/O Resource sharing and protection –among processes, users, computers –authentication, authorization, accounting Different interfaces to these services –regular user, application programmer, system programmer, system designer

CSC 360- Instructor: K. Wu 4 2. Command line interface E.g. –Microsoft DOS: \command.com –Linux: /bin/bash Interactivity: interpreter Implementation –internal: dir (DOS), cd (DOS/Unix) –external: ls (Unix) Programmability: shell script

CSC 360- Instructor: K. Wu 5 3. Graphics user interface E.g. –Microsoft Windows –K Desktop Environment (KDE) Interactivity: point-and-click, drag-and-drop Implementation –integrated with OS –OS front-end Programmability: e.g., AutoIt

CSC 360- Instructor: K. Wu 6 4. System calls (1) Primitive interfaces to OS services System call categories –process control fork, exec*, wait, kill, signal, exit, etc –file/device manipulation creat[e], open, read, write, lseek, close, etc socket, bind, listen, accept, connect, etc –information manipulation time, getpid, getgid, gethostname, etc

CSC 360- Instructor: K. Wu 7 4. System call examples (2) Copy (the content of) file A to file B –in CLI: cp /path/to/a /path/to/b –in GUI: Ctrl-C and Ctrl-V, Ctrl-Drag With system calls –open(“/path/to/a”, O_RDONLY); –creat(“/path/to/b”, S_IRWXU); open() with O_CREAT|O_WRONLY|O_TRUNC –read() and write() –close()

CSC 360- Instructor: K. Wu 8 4. System call implementation (3) Software interrupt –e.g., INT21H in DOS –command: AH (e.g.,2A/2B: get/set system date) –parameters in registers on system stack in memory (pointed by registers) –return status: in specific registers –return data

CSC 360- Instructor: K. Wu 9 4. System call flows (4)

CSC 360- Instructor: K. Wu API (1) E.g. –Win32 API: Windows –POSIX API: Unix, Linux, OSX, (Windows) –Java API: Java JVM API: another layer of abstraction –mostly OS-independent –higher level of functionality implemented by a series of system calls and more

CSC 360- Instructor: K. Wu API (2): examples Copy (the content of) file A to file B With C library –fopen(“/path/to/a”, “r”); –fopen(“/path/to/b”, “w”); –fread() and fwrite() formatted I/O: element size, # of elements buffered I/O: streams –fclose()

CSC 360- Instructor: K. Wu API (3): flows

CSC 360- Instructor: K. Wu Unix manual Manual sections –1user commands –2system calls –3C library functions –4device and network interfaces –… E.g. –man 1 open; man 2 open