lesson 11 operating system basics. resource manager - resource include: cpu, memory, disk, network -...

33
lesson 11 Operating System Basics

Upload: britney-jenkins

Post on 21-Jan-2016

262 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

lesson 11

Operating System Basics

Page 2: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

• Resource Manager- Resource include: CPU, memory, disk, network- OS allocates and de-allocates these resources

• Virtual Machine- provides an abstraction of a larger (or just different machine)- Example:

- Virtual memory: looks like more memory

- Java: pseudo machine that looks like a stack machine

- IBM VM: a complete virtual machine• Multiplexor

- allows sharing of resources and protection

What is an Operating System

Page 3: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

• Provider of Services- includes most of the things in the above definitions- provide “common” subroutes for the programmer

- windowing systems- memory management

• The software that is always loaded/running

- generally refers to the OS kernel- small protected piece of software

• All of these definitions are correct- but not all operating have all of these features

What is OS (cont.)

Page 4: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

• Robustness- accept all valid input- detect and gracefully handle all invalid input- should not be possible to crash the OS

• Consistency- same operation should mean the same thing

* read from a file or a network should look the same

* a “-” flag should be the same in different commands- conventions

* define the convention* follow the convention when adding

new items

Usability Goals

Page 5: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

• Proportionality- simple, common cases are easy and fast

* good default values- complex, rare cases are possible but more complex and slower

* “rm” should give a warning* formatting the disk should not be on

the desktop next to the trash can

Usability Goals (cont.)

Page 6: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

This lesson includes the following sections:

• The User Interface

• Running Programs

• Managing Files

• Managing Hardware

• Utility Software

Page 7: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

• Graphical User Interfaces (GUIs)

• GUI Tools

• Applications and the Interface

• Menus

• Dialog Boxes

• Command-Line Interfaces

The User Interface

Page 8: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

• Graphical User Interfaces (GUIs)

• GUI Tools

• Applications and the Interface

• Menus

• Dialog Boxes

• Command-Line Interfaces

The User Interface

Page 9: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

• Most modern operating systems, like Windows and the Macintosh OS, provide a graphical user interface (GUI).

• A GUI lets you control the system by using a mouse to click graphical objects on screen.

• A GUI is based on the desktop metaphor. Graphical objects appear on a background (the desktop), representing resources you can use.

The User Interface - Graphical User Interfaces (GUIs)

Page 10: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

Icons

Start menu

Start button

Taskbar

Desktop

Dialog box

Programrunning ina window

Window control buttons

Page 11: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

• Icons are pictures that represent computer resources, such as printers, documents, and programs.

• You double-click an icon to choose (activate) it, for instance, to launch a program.

• The Windows operating system offers two unique tools, called the taskbar and Start button. These help you run and manage programs.

The User Interface - GUI Tools

Page 12: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

Or, icons can bedouble-clicked tolaunch programs.

The Windows startbutton can be usedto launch programs.

Page 13: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

• Applications designed to run under one operating system use similar interface elements.

• Under an OS such as Windows, you see a familiar interface no matter what programs you use.

• In a GUI, each program opens and runs in a separate window—a frame that presents the program and its documents.

• In a GUI, you can run multiple programs at once, each in a separate window. The application in use is said to be the active window.

The User Interface – Applications and the Interface

Page 14: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

Titlebar

Menubar

Toolbar

Scroll arrow

Scroll box

Scroll bar

Click the Minimize button to reducethe program to a button on the taskbar.Click the Maximize button to restorethe window to its previous size.

Click the Close button to closethe window altogether.

Page 15: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

• GUI-based programs let you issue commands by choosing them from menus.

• A menu groups related commands. For example, the File menu's commands let you open, save, and print document files.

• Menus let you avoid memorizing and typing command names.

• In programs designed for the same GUI, menus and commands are similar from one program to another.

The User Interface - Menus

Page 16: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual
Page 17: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

• A dialog box is a special window that appears when a program or the OS needs more information before completing a task.

• Dialog boxes are so named because they conduct a "dialog" with the user, asking the user to provide more information or make choices.

The User Interface - Dialog Boxes

Page 18: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual
Page 19: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

• Some older operating systems, such as DOS (Disk Operating System) and UNIX, use command-line interfaces.

• In a command-line interface, you type commands at a prompt.

• Under command-line interfaces, individual applications do not need to look or function the same way, so different programs can look very different

.

The User Interface - Command-Line Interfaces

Page 20: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

The DOS Prompt is not seen much these days!

Page 21: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

• Basic Services

• Sharing Information

• Multitasking

Running Programs

Page 22: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

• The operating system manages all the other programs that run on the PC.

• The operating system provides services to programs and the user, including file management, memory management, and printing

• To provide services to programs, the OS makes system calls—requesting other hardware and software resources to perform tasks.

Running Programs - Basic Services

Page 23: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

• Some operating systems, such as Windows, enable programs to share information.

• You can create data in one program and use it again in other programs without re-creating it.

• Windows provides the Clipboard, a special area that stores data cut or copied from one document, so you can re-use it elsewhere.

Running Programs - Sharing Information

Page 24: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

1

2

3

Information is clippedfrom one application (Excel)

Using the clipboard Viewer toexamine the information

Pasting the informationinto another application (WordPro)

Page 25: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

• Multitasking is the capability of running multiple processes simultaneously.

• A multitasking OS lets you run multiple programs at the same time.

• Through multitasking, you can do several chores at one time, such as printing a document while downloading a file from the Internet.

• There are two types of multitasking: cooperative and preemptive.

Running Programs - Multitasking

Page 26: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual
Page 27: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

• The operating system keeps track of all the files on each disk.

• Users can make file management easier by creating a hierarchical file system that includes folders and subfolders arranged in a logical order.

Managing Files

Page 28: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual
Page 29: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

• The OS uses interrupt requests (IRQs) to maintain organized communication with the CPU and other pieces of hardware.

• Each hardware device is controlled by a piece of software, called a driver, which allows the OS to activate and use the device.

• The operating system provides the software necessary to link computers and form a network.

Managing Hardware

Page 30: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual
Page 31: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

A utility is a program that performs a task that is not typically handled by the operating system.

Some utilities enhance the operating system's functionality.

Some of the major categories of utilities include:• File defragmentation• Data compression• Backup• Antivirus• Screen savers

Utility Software

Page 32: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

lesson 11 review

• Name four components found in most graphical user interfaces.

• Describe the operating system’s role in running software programs.

• Explain how the OS enables users to manage files.

• List three hardware management tasks performed by an OS.

• Name five types of utility software.

Page 33: Lesson 11 Operating System Basics. Resource Manager - Resource include: CPU, memory, disk, network - OS allocates and de-allocates these resources Virtual

Project 4 due Oct. 29 • Login to Unix or Linux machine and run the following commands: • script t • whoami • man passwd• passwd • w • finger ccf• finger • pwd• arch • ls • ls -la • ls –lt • which latex • df –k• du -s• date• ps • exit • more t• cp t t1• mv t t2• cat t2• diff t1 t2• chmod 700 t1

http://www.cmlab.csie.ntu.edu.tw/~locking/IntroCS.htm