Table of Contents
Operating System Review
Chapter 1 Introduction to Operating Systems
Chapter 2 Processor Management
Chapter 3 Synchronization, communication and deadlock
Semaphore and PV operation: p134
Deadlock
Chapter 4 Storage Management
Chapter 5 Device Management
Reference bibliography:

Summary of operating system skills

Jul 20, 2017 pm 05:48 PM
review operating system notes

Operating System Review

Chapter 1 Introduction to Operating Systems

Definition: Manage system resources, control program execution, improve human-computer interface, provide various services, and rationally organize computer workflow And a system software that provides a good operating environment for users to use computers conveniently and effectively.
Functions: Processor management, storage management, device management, file management, networking and communication management
Features: Concurrency, sharing (1. Transparent resource sharing 2. Exclusive resource sharing), asynchrony
Category: batch operating system, time-sharing operating system, real-time operating system

Chapter 2 Processor Management

Process Definition: A process is a program with independent functions on a certain data collection A running activity is also the basic unit for resource allocation and protection by the operating system.
Process status and transition: p73
Three-state model: running state, ready state, waiting state
Five-state model: new state, terminated state What is the reason for the proposal?
Requires the ability to draw pictures to explain that certain transformations do not exist.

The motivation for introducing multi-threading: reducing the time and space overhead incurred when programs are executed concurrently, making concurrency granularity finer and concurrency better.
Advantages of threads: fast thread switching, easy communication, reduced management overhead, and improved concurrency

PCB (Process Control Block) process control block: the unique identifier of the existence of a process, which is used by the operating system to record It is the collection of dynamic characteristics of the process and the data structure that describes the process status and environmental information. It is also the only data structure for the operating system to control the process and the main basis for managing the process. p75

What is the concept of TCB?
Dynamic/static priority?

Processor Scheduling: p101 Example

  1. First come, first served algorithm

  2. Shortest job first algorithm (concept)

  3. Shortest remaining time priority algorithm

  4. Highest response ratio priority algorithm (concept)

Chapter 3 Synchronization, communication and deadlock

Bernstein conditions? Bernstein (short answer)

Deadlock: A group of processes is stuck in a state of waiting forever due to competition for resources.
Hunger: A runnable process is delayed indefinitely by the scheduler and cannot be executed because other processes always take precedence over it.

Process synchronization: Concurrent processes to complete a common task coordinate their activities based on a certain condition, because the coordination constraints caused by waiting for and transmitting signals or messages need to be arranged in the order of execution at certain locations. relation.

Critical section: Program segment related to shared variables in concurrent processes.
Critical resources: The resources represented by shared variables, that is, resources that can only be used by one process at a time.
Three principles of critical section scheduling (mutually exclusive use, let in when free; wait if busy, limited wait; choose one to enter, the algorithm is feasible.):

  1. At most one process can enter the critical section for execution at a time.

  2. If there is already a process in the critical section, other processes trying to enter this critical section should wait.

  3. The process entering the critical section should exit within a limited time to allow a process in the waiting queue to enter.

Software algorithm for critical section management:
Analysis

  1. Will there be any problems?

  2. When will it be released?

Hardware facilities for critical section management:

  1. Turn off interrupts

  2. Test and set instructions

  3. Swap instructions

Semaphore and PV operation: p134

pv operation definition (one yuan, general)?
Comprehensive question:

  1. The 5 philosophers dining problem (no deadlock solution) p139

  2. Producer-consumer problem ( Many-to-many, many buffers) p140

  3. Reader-writer problem p141

  4. Barber problem p142

  5. Monk Fetching Water

Deadlock

Definition: If each process in a process set is waiting, it can only wait for other processes in the set. The process can only cause events, and it will be stuck in a stalemate indefinitely.
Generated conditions:

  1. Mutually exclusive conditions

  2. Possession and waiting conditions

  3. No deprivation condition

  4. Loop waiting condition

Deadlock avoidance: Comprehensive question 15 points
Banker’s algorithmData structure p163
Algorithm description:

  1. Safety sequence at time T0

  2. Process P1 requests resources (can it be satisfied? Why? )

Chapter 4 Storage Management

Program link type: (fill in the blank)

  1. Static link

  2. Dynamic link

  3. Runtime link

Static address relocation: The loader implements the loading and address conversion of the loading code, loads it into the designated area of ​​memory allocated to the process, and all logical addresses in it are modified into a memory physical address.
Dynamic address relocation: The loader implements the loading of the loading code module and loads it into the designated area of ​​​​the memory allocated to the process, but the logical address of the application processed by the linker is not When any modification is made, the starting address of the program memory is placed into the hardware special register - the relocation register. During program execution, whenever the CPU refers to a memory address (accessing programs and data), the hardware intercepts this logical address and adds the value of the relocation register before it is sent to the memory in order to achieve address translation.

Paging storage management p206
Concept:

  1. Page

  2. Page frame

  3. Logical address

  4. Memory page frame table

  5. Page table

Paging/ What is the implementation principle of segmented dynamic link library? (Explanation + Drawing)

Comprehensive question:

  1. Given the logical address, find the physical address? (Draw)

  2. Given the logical address and page size, calculate the physical address?

Comparison of segmentation and paging (short answer):
Segmentation is a logical unit of information, determined by the logical structure and meaning of the source program , visible to the user, the segment length is determined by the user according to needs, and the segment start address can start from any memory address. In the segmented method, the source program (short number, intra-segment displacement) still maintains a two-dimensional (address) structure after being linked and assembled. The purpose of introduction is to meet the needs of users for modular programming.
Paging is a physical unit of information. It has nothing to do with the logical structure of the source program and is invisible to the user. The page length is determined by the system (hardware). The page can only start from an integer multiple of the page size. In the paging mode, the source program (page number, intra-page displacement) becomes a one-dimensional (address) structure after link assembly. The purpose of introduction is to achieve discrete allocation and improve memory utilization.

Page fault interruption rate p223
Concept: Number of unsuccessful accesses?
Draw a picture, find the page missing interruption rate? p229

Chapter 5 Device Management

I/O control method: (fill in the blank)

  1. Polling method

  2. Interrupt mode

  3. DMA mode

  4. Channel mode

Buffer technology:
Single buffering p265
Double buffering p266

Search positioning: (example questions, short answers) p270

  • First come, first served algorithm

  • Shortest search time first algorithm

  • Scan algorithm

  • Elevator scheduling algorithm

  • Cycle Scan Algorithm

Reference bibliography:

-"Operating System Tutorial (Fifth Edition)" by Fei Xianglin and Luo Bin Higher Education Press

The above is the detailed content of Summary of operating system skills. For more information, please follow other related articles on the PHP Chinese website!

Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

How to create oracle database How to create oracle database How to create oracle database How to create oracle database Apr 11, 2025 pm 02:36 PM

To create an Oracle database, the common method is to use the dbca graphical tool. The steps are as follows: 1. Use the dbca tool to set the dbName to specify the database name; 2. Set sysPassword and systemPassword to strong passwords; 3. Set characterSet and nationalCharacterSet to AL32UTF8; 4. Set memorySize and tablespaceSize to adjust according to actual needs; 5. Specify the logFile path. Advanced methods are created manually using SQL commands, but are more complex and prone to errors. Pay attention to password strength, character set selection, tablespace size and memory

Do mysql need to pay Do mysql need to pay Apr 08, 2025 pm 05:36 PM

MySQL has a free community version and a paid enterprise version. The community version can be used and modified for free, but the support is limited and is suitable for applications with low stability requirements and strong technical capabilities. The Enterprise Edition provides comprehensive commercial support for applications that require a stable, reliable, high-performance database and willing to pay for support. Factors considered when choosing a version include application criticality, budgeting, and technical skills. There is no perfect option, only the most suitable option, and you need to choose carefully according to the specific situation.

Can mysql run on android Can mysql run on android Apr 08, 2025 pm 05:03 PM

MySQL cannot run directly on Android, but it can be implemented indirectly by using the following methods: using the lightweight database SQLite, which is built on the Android system, does not require a separate server, and has a small resource usage, which is very suitable for mobile device applications. Remotely connect to the MySQL server and connect to the MySQL database on the remote server through the network for data reading and writing, but there are disadvantages such as strong network dependencies, security issues and server costs.

What is Linux actually good for? What is Linux actually good for? Apr 12, 2025 am 12:20 AM

Linux is suitable for servers, development environments, and embedded systems. 1. As a server operating system, Linux is stable and efficient, and is often used to deploy high-concurrency applications. 2. As a development environment, Linux provides efficient command line tools and package management systems to improve development efficiency. 3. In embedded systems, Linux is lightweight and customizable, suitable for environments with limited resources.

Where is the Redis restart service Where is the Redis restart service Apr 10, 2025 pm 02:36 PM

How to restart the Redis service in different operating systems: Linux/macOS: Use the systemctl command (systemctl restart redis-server) or the service command (service redis-server restart). Windows: Use the services.msc tool (enter "services.msc" in the Run dialog box and press Enter) and right-click the "Redis" service and select "Restart".

Who invented the mac system Who invented the mac system Apr 12, 2025 pm 05:12 PM

The macOS operating system was invented by Apple. Its predecessor, System Software, was launched in 1984. After many iterations, it was updated to Mac OS X in 2001 and changed its name to macOS in 2012.

What are the methods of tuning performance of Zookeeper on CentOS What are the methods of tuning performance of Zookeeper on CentOS Apr 14, 2025 pm 03:18 PM

Zookeeper performance tuning on CentOS can start from multiple aspects, including hardware configuration, operating system optimization, configuration parameter adjustment, monitoring and maintenance, etc. Here are some specific tuning methods: SSD is recommended for hardware configuration: Since Zookeeper's data is written to disk, it is highly recommended to use SSD to improve I/O performance. Enough memory: Allocate enough memory resources to Zookeeper to avoid frequent disk read and write. Multi-core CPU: Use multi-core CPU to ensure that Zookeeper can process it in parallel.

Navicat's method to view SQLite database password Navicat's method to view SQLite database password Apr 08, 2025 pm 09:36 PM

Summary: Navicat cannot view SQLite passwords because: SQLite does not have traditional password fields. SQLite's security relies on file system permission control. If the file password is forgotten, it cannot be retrieved (unless the database is encrypted, the key is required).

See all articles