Operating Systems: Computer System Structure

Choose a study mode

Play Quiz
Study Flashcards
Spaced Repetition
Chat to Lesson

Podcast

Play an AI-generated podcast conversation about this lesson
Download our mobile app to listen on the go
Get App

Questions and Answers

Which component of a computer system directly controls and coordinates the use of hardware among various applications and users?

  • Operating system (correct)
  • Application programs
  • User
  • Hardware

Which of the following best describes the role of an operating system?

  • A tool for writing documents and spreadsheets
  • A resource allocator and control program (correct)
  • A type of computer hardware
  • A high-level programming language

Why is the concept of resource utilization not the primary concern for users interacting with operating systems?

  • Because they are primarily concerned with the underlying efficiency of the systems.
  • Because hardware is becoming cheaper and more efficient.
  • Because their main focus is on the convenience and ease of use of the system. (correct)
  • Because the operating system automatically optimizes resource utilization.

Which of the following represents a modern trend in operating systems?

<p>The proliferation of specialized operating systems in embedded devices. (D)</p>
Signup and view all the answers

What is the key function of the 'kernel' in an operating system?

<p>Serving as the core that remains running at all times. (A)</p>
Signup and view all the answers

What is the role of 'middleware' in modern operating systems, particularly in mobile computing?

<p>To provide additional services to application developers. (C)</p>
Signup and view all the answers

How do device controllers communicate with the CPU?

<p>Through shared memory and interrupts (C)</p>
Signup and view all the answers

Which of the following accurately describes an interrupt?

<p>A signal that prompts the CPU to switch tasks. (C)</p>
Signup and view all the answers

What is the primary function of an interrupt vector?

<p>To store the addresses of all interrupt service routines. (A)</p>
Signup and view all the answers

What distinguishes a 'trap' (or exception) from other types of interrupts?

<p>It is initiated by software, often due to an error or user request. (A)</p>
Signup and view all the answers

Why is main memory considered 'volatile'?

<p>Because its data is lost when power is removed. (C)</p>
Signup and view all the answers

What is the role of a disk controller?

<p>To determine the logical interaction between the device and the computer. (B)</p>
Signup and view all the answers

How does caching improve system performance?

<p>By copying information into faster storage systems. (D)</p>
Signup and view all the answers

What is the primary role of a device driver?

<p>To provide a uniform interface between a controller and the kernel. (D)</p>
Signup and view all the answers

What is a key advantage of using multiprocessor systems?

<p>Lower cost due to economy of scale. (C)</p>
Signup and view all the answers

In asymmetric multiprocessing, how are tasks allocated among the processors?

<p>Each processor is assigned a specific task. (A)</p>
Signup and view all the answers

Which of the following best describes symmetric multiprocessing?

<p>A system where each processor performs all tasks. (B)</p>
Signup and view all the answers

What is a primary characteristic of clustered systems?

<p>They consist of multiple systems working together. (B)</p>
Signup and view all the answers

What is the function of a distributed lock manager (DLM) in clustered systems?

<p>To avoid conflicting operations. (C)</p>
Signup and view all the answers

What role does firmware play in the computer startup process?

<p>It initializes all aspects of the system. (D)</p>
Signup and view all the answers

What is the purpose of Direct Memory Access (DMA)?

<p>To allow high-speed I/O devices to transfer data directly to main memory. (A)</p>
Signup and view all the answers

What is the main goal of multiprogramming?

<p>To keep the CPU busy at all times. (B)</p>
Signup and view all the answers

How does multitasking enhance user experience?

<p>By allowing users to interact with each job while it is running. (B)</p>
Signup and view all the answers

What is meant by 'swapping' in an operating system?

<p>Moving processes between main memory and secondary storage. (B)</p>
Signup and view all the answers

What is the concept of a 'process' in an operating system?

<p>A program in execution. (D)</p>
Signup and view all the answers

What is the primary benefit of dual-mode operation in an operating system?

<p>To allow the OS to protect itself and system components. (D)</p>
Signup and view all the answers

What is the role of 'process synchronization' in process management?

<p>Coordinating execution to maintain data consistency. (A)</p>
Signup and view all the answers

In the context of memory management, what activity does the operating system perform?

<p>Deciding which processes ( or parts thereof) and data to move into and out of memory (C)</p>
Signup and view all the answers

What is the main purpose of mass-storage management?

<p>Managing data that doesn't fit in main memory. (B)</p>
Signup and view all the answers

What best describes 'cache coherency' in a multiprocessor environment?

<p>It ensures all CPUs have the most recent value in their cache. (B)</p>
Signup and view all the answers

What does the operating system's I/O subsystem primarily manage?

<p>Memory management of I/O including buffering and caching (A)</p>
Signup and view all the answers

What is a file in the context of file-system management?

<p>A logical storage unit. (C)</p>
Signup and view all the answers

In the context of operating systems, what does 'protection' refer to?

<p>Controlling access of processes or users to resources. (C)</p>
Signup and view all the answers

How do operating systems typically distinguish among users?

<p>By uniquely assigned User IDs. (B)</p>
Signup and view all the answers

When does 'emulation' come into play in Operating Systems?

<p>When the source CPU is different from the target type. (A)</p>
Signup and view all the answers

According to the use cases mentioned, when is virtualization typically used?

<p>Desktops running multiple OSes for exploration or compatibility (B)</p>
Signup and view all the answers

What is a defining characteristic of a Network Operating System in a distributed system?

<p>It enables communication. (A)</p>
Signup and view all the answers

What feature is commonly included in mobile computing environments?

<p>Augmented reality (B)</p>
Signup and view all the answers

What type of system provides an interface for clients to store and retrieve files?

<p>File-server system (B)</p>
Signup and view all the answers

How do nodes discover services made available on a Peer-to-Peer network?

<p>Registers its service with central lookup service or broadcasts request for service using discovery protocol (D)</p>
Signup and view all the answers

What is the meaning of Software as a Service (SaaS)?

<p>One or more applications available via the Internet (B)</p>
Signup and view all the answers

For cloud computing environments composed of traditional OSes, what else is included?

<p>VMMs and cloud management tools (D)</p>
Signup and view all the answers

For embedded systems using a real-time OS, what must be met?

<p>Correct operation only if constraints met (C)</p>
Signup and view all the answers

Flashcards

Operating System

A program that acts as an intermediary between a user of a computer and the computer hardware.

Operating System main function

Controls and coordinates the use of hardware among various applications and users.

Operating System goal: Execution

Enables user programs to run and solve user problems more easily.

Operating System responsibility in shared systems

Maintains a shared computer system to satisfy all users.

Signup and view all the flashcards

Operating system functions

Allocates resources and controls program execution.

Signup and view all the flashcards

Kernel

A program that is always running on the computer and is the core of the operating system.

Signup and view all the flashcards

System Program

Ships with the OS but is not part of the kernel.

Signup and view all the flashcards

Application Program

A program not associated with the operating system.

Signup and view all the flashcards

Bus in Computer Systems

Provides shared memory access to CPUs, device controllers connect through this.

Signup and view all the flashcards

Memory in Computer Systems

The main memory that stores data and instructions for computer operations.

Signup and view all the flashcards

CPU Data Movement

Data is moved from main memory to local buffers and vice versa.

Signup and view all the flashcards

Interrupt

A signal sent by the device controller to the CPU when an operation is completed.

Signup and view all the flashcards

Interrupt Vector

Method to finds the appropriate routine by calling the addresses of service routines.

Signup and view all the flashcards

Main Memory

Memory that the CPU can directly access, typically volatile.

Signup and view all the flashcards

Secondary Storage

An extension of main memory; provides large, nonvolatile storage capacity.

Signup and view all the flashcards

Hard Disk Drive (HDD)

Rigid metal or glass platters covered with magnetic recording material.

Signup and view all the flashcards

Non-Volatile Memory (NVM)

Faster than hard disks, nonvolatile.

Signup and view all the flashcards

Memory as Cache

Main memory can be viwed as one of these for secondary storage.

Signup and view all the flashcards

Device Driver

Provides a uniform interface between the device controller and the kernel.

Signup and view all the flashcards

Multiprocessor Systems

Systems that use multiple processors to increase throughput and reliability.

Signup and view all the flashcards

Asymmetric Multiprocessing

Dividing tasks between processors. Each processor is assigned a specific task.

Signup and view all the flashcards

Symmetric Multiprocessing

Each processor performs all tasks within the operating system.

Signup and view all the flashcards

High-Availability

Services which survive failures by providing high availability.

Signup and view all the flashcards

Bootstrap Program

A program loaded at power-up or reboot that initializes the system.

Signup and view all the flashcards

Firmware

The program is stored in ROM or EPROM.

Signup and view all the flashcards

Interrupt Vector

Interrupts transfer control through this, which contains the addresses of service routines.

Signup and view all the flashcards

Multiprogramming

When a job has to wait, the OS switches to another job.

Signup and view all the flashcards

Multitasking

A logical extension of batch systems where the CPU switches jobs frequently.

Signup and view all the flashcards

Process

A state where a program is running.

Signup and view all the flashcards

Resources needed by processes

Is a unit of work within the system consisting of CPU, memory, I/O and files.

Signup and view all the flashcards

Dual-Mode Operation

Allows the OS to protect itself and other system components.

Signup and view all the flashcards

Kernel-Mode-Only

This happens with the operating system if instructions are priviledged.

Signup and view all the flashcards

Caching

Copying information into faster storage system; main memory acts as a cache for secondary storage

Signup and view all the flashcards

Disk Protection

Protects a storage or data from non-access.

Signup and view all the flashcards

Network

A communications path, its most commonly TCP/IP.

Signup and view all the flashcards

Portals

Portals provide web access to internal systems.

Signup and view all the flashcards

Mobile OS Connectivity

Use IEEE 802.11 wireless, or cellular data networks for connectivity.

Signup and view all the flashcards

Compute-Server System

Provides an interface to client to request services.

Signup and view all the flashcards

File-Server System

Provides interface for clients to store and retrieve files

Signup and view all the flashcards

Cloud Computing

Delivers computing, storage, even apps as a service across a network.

Signup and view all the flashcards

Study Notes

  • Maria Fazio is the professor for Operating Systems at the Università degli Studi di Messina.
  • Operating Systems is a course at CdL in Informatica.

Computer System

  • Standard components including a monitor, external speaker, keyboard and mouse.
  • Internal components include RAM chips, expansion slots, video card, network card, A/V card, internal speaker, computer tower, power supply, cooling fan, floppy drive, CD/DVD-ROM drive, CD-RW drive, hard drive, battery, microprocessor, cooling blades, clock and motherboard.

Von Neumann Architecture

  • Memory, Input/Output Interfaces and CPU are the primary blocks.
  • The CPU contains the registers and ALU.
  • Memory has a mass memory component.
  • Interfaces connect to Video/keyboard.
  • BUS carries data, addresses and control signals.

Computer System Structure

  • Computer systems are composed of hardware, OSs, application programs and users.
  • Users include People, machines, other computers who need computing resources.
  • Application programs define how the system resources solve user problems.
  • Word processors, compilers, web browsers, database systems, and video games are examples of application programs.
  • The OS controls and coordinates the use of hardware among applications and users.
  • Hardware provides basic computing resources like the CPU, memory, and I/O devices.

Operating System Goals

  • OSs act as intermediaries between computer users the computer hardware.
  • Execute user programs and make problem-solving easier.
  • They aim to make computer systems convenient and use hardware efficiently.

What Operating Systems Do

  • Shared computers, like mainframes or minicomputers, must keep all users happy by efficiently managing hardware use and program execution as a resource allocator and control program.
  • Dedicated systems, like workstations, use dedicated resources but share from servers.
  • Mobile devices are resource-poor and are optimized for usability and battery life with mobile user interfaces such as touch screens and voice recognition.
  • Embedded computers in devices and automobiles have little to no user interface, running primarily without user intervention.

Defining Operating Systems

  • An OS term covers many roles.
  • They exist in various devices such as toasters, ships, spacecraft, game machines, TVs and industrial control systems due to myriad designs and uses.
  • OSs emerged when fixed-use military computers became more general and needed resource management and program control.

Different Operating Systems

  • Mac OS is a series of graphical user interface-based operating systems developed by Apple Inc. for their Macintosh computers.
  • Linux is a Unix-like computer operating system assembled under the model of free and open source software development and distribution.
  • Microsoft Windows is a series of graphical interface operating systems developed, marketed, and sold by Microsoft.
  • iOS (previously iPhone OS) is a mobile OS developed and distributed by Apple Inc,.
  • Android is a Linux-based operating system designed primarily for touchscreen mobile devices.
  • BSD/OS was known for its reliability in server roles.

Evolution of Operating Systems

  • Operating Systems have evolved from Serial Processing to Batch Processing, Multiprogramming, Time Sharing, Parallel Systems, Network-based and finally to Distributed Systems.

Operating System Definition

  • An OS is the set of basic programs and utilities that enable a computer to run.
  • The kernel is the program that runs at all times on the computer
  • Everything else is either a system program or an application program.
  • System programs ship with the OS but are not part of the kernel.
  • Application programs are programs not associated with the OS.
  • Today's OS often include middleware with software frameworks for databases, multimedia, and graphics.

Computer System Organization

  • Computer system operation comprises of CPUs, device controllers and memory connected by a common bus
  • Multiple CPUs and devices concurrently compete for memory cycles

Computer-System Operation

  • I/O devices and the CPU can execute concurrently managed by device drivers.
  • Each device controller manages a specific device type.
  • Each controller has a local buffer.
  • The CPU moves data to/from main memory to/from the local buffers.
  • The I/O operates from the buffer of controller.
  • The device controller informs the CPU of completed operations through an interrupt.

Common Functions of Interrupts

  • Interrupts transfer control to an interrupt service routine through the interrupt vector, which contains the addresses of all service routines.
  • Interrupt architecture must save the address of the interrupted instruction.
  • A trap or exception is a software-generated interrupt caused by an error or a user request.
  • An OS is interrupt-driven.

Storage Structure

  • Main memory is the only large storage the CPU can access directly using random access and is typically volatile.
  • It consists of random-access memory in the form of Dynamic Random-access Memory (DRAM).
  • Secondary storage supplements main memory with large, nonvolatile storage capacity.

Storage Structure (Cont.)

  • Hard Disk Drives (HDDs) have rigid metal or glass platters covered with magnetic recording material.
  • Disk surfaces are logically divided into tracks, which are further subdivided into sectors with interactions is managed by disk controller.
  • Non-Volatile Memory (NVM) is faster and nonvolatile.
  • Modern Non-Volatile Memory is becoming more popular as capacity and performance increases with price drops.

Storage Definitions and Notation Review

  • The bit is the basic unit of computer storage.
  • A bit holds either 0 or 1.
  • Storage is measured in bytes as 8 bits; this is the smallest convenient chunk of storage on most computers.
  • Word is a less common term defined as a given computer architecture's native unit of data made up of one or more bytes.
  • A computer executes instructions at its native word size rather than by the byte.
  • A computer with 64-bit registers typically has 64-bit (8-byte) words.
  • Storage is measured in bytes as the following:
    • A kilobyte (KB) is 1,024 bytes.
    • A megabyte (MB) is 1,024^2 bytes.
    • A gigabyte (GB) is 1,024^3 bytes.
    • A terabyte (TB) is 1,024^4 bytes.
    • A petabyte (PB) is 1,024^5 bytes.

Storage Hierarchy

  • Storage systems are organized in a hierarchy based on speed, cost, and volatility.
  • Caching copies information into a faster storage system, where main memory acts as a cache for secondary storage.
  • Each device controller has a device driver to manage I/O, which provides a uniform interface between the controller and kernel.

Computer-System Architecture

  • Most systems use a single general-purpose processor but may have special-purpose processors.
  • Parallel or tightly-coupled systems are growing in use.
  • Advantages of multiprocessor systems are increased throughput, economy of scale, and increased reliability through graceful degradation or fault tolerance.
  • Asymmetric Multiprocessing assigns each processor a specific task.
  • Symmetric Multiprocessing assigns each processor performs all tasks.

Clustered Systems

  • Clustered systems are like multiprocessor systems but involve multiple systems working together.
  • They share storage via a storage-area network (SAN).
  • Clustered systems provide high-availability that can survive failures.
  • Asymmetric clustering has one machine in hot-standby mode.
  • Symmetric clustering has multiple nodes running applications and monitoring each other.
  • Some clusters are for high-performance computing (HPC) designed with special applications that use parallelization.
  • Some use a distributed lock manager (DLM) to avoid conflicting operations.

PC Motherboard

  • Provides all components of a computer

Computer Startup

  • A bootstrap program initializes the system and loads the operating system kernel, beginning execution,
  • The bootstrap program is loaded at power-up or reboot and is typically stored in ROM or EPROM, as firmware.

How a Modern Computer Works

  • Through a thread of execution via instruction execution cycle
  • Movement between the CPU, cache memory, device and memory
  • Following A von Neumann architecture

Direct Memory Access Structure

  • It is essential for high-speed I/O devices able to transmit data close to memory speeds.
  • Device controllers transfer blocks of data from buffer storage directly to main memory without CPU intervention.
  • Only one interrupt is generated per data block, not per byte.

Multiprogramming (Batch system)

  • Single users cannot always keep the CPU and I/O devices busy.
  • Multiprogramming organizes code and data so the CPU always has one to execute.
  • A subset of total jobs in system is kept in memory.
  • One job is selected and run via job scheduling.
  • When a job waits (for I/O, for example), the OS switches to another job.

Multitasking (Timesharing)

  • Multitasking is a logical extension of batch systems where the CPU switches jobs so frequently that users can interact with each job in real time, enabling interactive computing.
  • Response time should be < 1 second.
  • Each user has at least one program executing in memory that represents a process.
  • If several jobs are ready to run simultaneously CPU scheduling takes place.
  • Swapping moves partially executed tasks in or out of memory if processes don't fit in memory.
  • Virtual memory allows the execution of processes that are not fully stored in memory.

Process Management

  • Is about running a program
  • A process is a unit of work within the system.
  • Program is a passive entity; process is an active entity.
  • Processes need resources like CPU, memory, I/O and files, and initialization data to accomplish its task.
  • Process termination requires the reclaim of reusable resources.

Dual-mode Operation

  • Dual-mode operation allows the OS to protect itself and other system components by differentiating between user mode and kernel mode.
  • Instructions designated as privileged are only executable in kernel mode.

Process Management Activities

  • Creating and deleting both user and system processes.
  • Suspending and resuming processes.
  • Providing mechanisms for process synchronization and communication.
  • Providing mechanisms for deadlock handling.

Process Management

  • Single-threaded processes have one program counter specify the location of the next instruction.
  • It executes instructions sequentially until completion.
  • Multi-threaded processes have one program counter per thread.
  • A system typically has many user and OS processes running concurrently on one or more CPUs.
  • Concurrency uses the multiplexing of processes or threads.

Memory Management

  • Executes a program with all or part of the the instructions in memory
  • Instructions are executed using the data in memory
  • It Optimizes CPU utilization and computer response to users
  • Activities include the following:
    • Keeping track of which parts of memory are actively used and by whom.
    • Deciding which processes and data will be moved into or out of memory.
    • The OS allocates and deallocates memory space as needed.

Mass-Storage Management

  • Disks are mainly used to store data
  • Proper management is of central importance
  • The whole speed operations hinges on the disk subsystem and it's algorithms.
  • OS activities include the following:
    • Mounting and unmounting
    • Free-space management
    • Storage allocation
    • Disk scheduling
    • Partitioning
    • Protection

Caching

  • The most important principle, performed at many levels in the computer.
  • Information in use copied from slower to faster storage, temporarily.
  • Faster storage (cache) is checked first to determine the presence of information, and used directly if present.
  • Cache is smaller than storage being cached
  • Includes Cache management, important design problem, Cache size and replacement policy

Characteristics of Various Types of Storage

  • Registers are the fastest and smallest storage, followed by cache, main memory, solid-state disk, and magnetic disk, which is slowest and largest.
  • Movement between the different levels of storage hierarchy can be explicit or implicit.

I/O Subsystem

  • A primary purpose of the OS is to hide the complexities of hardware devices.
  • Memory management of I/O includes buffering, caching, and spooling.
  • It is responsible for providing the general device-driver interface and drivers for specific hardware.

File-system Management

  • The OS provides a uniform and logical view of information storage.
  • It abstracts physical properties to logical storage unit as a file
  • Each medium is controlled by device (i.e., disk drive, tape drive)
  • Varying properties include access speed, capacity, data-transfer rate, access method (sequential or random)
  • File-System management includes the following: - Files usually organized into directories - Access control on most systems -OS activities include creating/deleting files/directories; primitives to manipulate files/directories; mapping files onto secondary storage; backing up files onto stable (non-volatile) storage media.

Protection and Security

  • Protection includes access to controlling processes, and resources defined by the OS.
  • Security is the defense of the system against internal and external attacks like denial-of-service, worms, viruses, and identity theft.
  • User identities (user IDs, security IDs) include names and associated numbers, one per user.
  • User IDs are associated with all files and processes.
  • Group identifiers (group IDs) controlling a set of users are associated with each process and file.
  • Privilege escalation is the ability for users to change an effective ID with more rights.

Virtualization

  • Operating systems run via applications run within other OSes.
  • Emulation is used when the CPU is different (i.e. PowerPC to Intel x86) and is generally the slowest.
  • Virtualization allows the OS to be compiled natively for the CPU and running guest OSes.
  • In virtualization, VMM (virtual machine Manager) provides virtualization services.

Virtualization (cont.)

  • Virtualization is used to explore multiple OSes for compatibility or run Windows as a guest on macOS.
  • Used in the software development process.
  • Quality assurance is used for testing applications without having multiple systems. VMMs can run natively with not general-purpose hosts.
  • VMMs include VMware ESX and Citrix XenServer

Distributed Systems

  • A collection of separate, networked systems
  • Use a Network as communications path, TCP/IP most common
  • Networks include the following:
    • Local Area Network (LAN)
    • Wide Area Network (WAN)
    • Metropolitan Area Network (MAN)
    • Personal Area Network (PAN)
  • Network Operating Systems provide features between systems across network
  • Communication schemes enable systems to exchange messages

Computing Environments

  • Computing environments include basic, mobile, client server, peer-to-peer, cloud computing, and real-time embedded.

Basic Approach

  • Utilizes stand-alone general-purpose machines.
  • Systems have interconnected with internet Portals
  • Provides web access to internal systems.
  • Interconnected network, including home systems interconnected wireless networks
  • Firewalls are used to protect home computers.

Mobile

  • Includes smartphones, tablets, extra OS features like GPS, gyroscope, and augmented reality
  • Wireless networks connectivity - IEEE 802.11 wireless or cellular data networks
  • Apple iOS and Google Android are among the leaders.

Client-Server Computing

  • Dumb terminals supplanted by smart PCs now as client generated servers.
  • Compute-server system provides an interface to client to request services (i.e. database)
  • File-server system provides interface for clients to store and retrieve files

Peer to Peer

  • It does not distinguish clients and servers
  • Every node acts as a Client, server, or both
  • The node must be able to join
  • Includes Napster and Skype

Cloud Computing

  • Delivers computing, storage, and apps as a service across a network based on virtualization.
  • Amazon EC2 has thousands of servers, VMs, petabytes of storage to share.
  • Public cloud is available via the Internet for pay.
  • The hybrid cloud includes both public and private cloud components.
  • SaaS provides applications like word processing over the Internet
  • PaaS supplies a software stack for application via the Internet
  • IaaS provides servers or storage over the Internet

Cloud Computing (cont.)

  • Cloud computing environments are composed of traditional OSes, VMMs, and other cloud management tools with internet connectivity require safety
  • Load balancers spread traffic across multiple applications.

Real-Time Embedded Systems

  • Real-time embedded systems are special purpose, with a limited OS, real-time OS.
  • May perform tasks without an OS
  • They have constraints with processing be done within them and operation only if constraints met.

Kernel Data Structures

  • Similar standard programming data structures like singly linked lists, doubly linked lists, and circular linked lists.
  • Includes Binary search trees and hash functions

Studying That Suits You

Use AI to generate personalized quizzes and flashcards to suit your learning preferences.

Quiz Team

More Like This

Use Quizgecko on...
Browser
Browser