Operating System 简明教程

Operating System Tutorial

操作系统 (OS) 是一组管理计算机硬件资源并为计算机程序提供通用服务的软件。当您开始使用计算机系统时,充当您和计算机硬件之间接口的就是操作系统 (OS)。操作系统实际上是一个低级别 Software ,被归类为 System Software ,并支持计算机的基本功能,例如内存管理、任务调度和控制外围设备等。

An Operating System (OS) is a collection of software that manages computer hardware resources and provides common services for computer programs. When you start using a Computer System then it’s the Operating System (OS) which acts as an interface between you and the computer hardware. The operating system is really a low level Software which is categorised as a System Software and supports a computer’s basic functions, such as memory management, tasks scheduling and controlling peripherals etc.

本简单易用的教程将带您详细学习操作系统概念,并采用循序渐进的方法。

This simple and easy tutorial will take you through step by step approach while learning Operating System concepts in detail.

What is Operating System?

操作系统 (OS) 是计算机用户和计算机硬件之间的接口。操作系统是一种执行所有基本任务的软件,例如文件管理、内存管理、进程管理、处理输入和输出以及控制外围设备(例如磁盘驱动器和打印机)。

An Operating System (OS) is an interface between a computer user and computer hardware. An operating system is a software which performs all the basic tasks like file management, memory management, process management, handling input and output, and controlling peripheral devices such as disk drives and printers.

通常, Computer System 包含以下组件:

Generally, a Computer System consists of the following components:

  1. Computer Users are the users who use the overall computer system.

  2. Application Softwares are the softwares which users use directly to perform different activities. These softwares are simple and easy to use like Browsers, Word, Excel, different Editors, Games etc. These are usually written in high-level languages, such as Python, Java and C++.

  3. System Softwares are the softwares which are more complex in nature and they are more near to computer hardware. These software are usually written in low-level languages like assembly language and includes Operating Systems (Microsoft Windows, macOS, and Linux), Compiler, and Assembler etc.

  4. Computer Hardware includes Monitor, Keyboard, CPU, Disks, Memory, etc.

那么现在让我们用简单的话来说明:

So now let’s put it in simple words:

Operating System - Examples

市场上有许多操作系统,包括付费和免费(开源)。以下列出了一些最流行的操作系统示例:

There are plenty of Operating Systems available in the market which include paid and unpaid (Open Source). Following are the examples of the few most popular Operating Systems:

  1. Windows: This is one of the most popular and commercial operating systems developed and marketed by Microsoft. It has different versions in the market like Windows 8, Windows 10 etc and most of them are paid.

  2. Linux This is a Unix based and the most loved operating system first released on September 17, 1991 by Linus Torvalds. Today, it has 30+ variants available like Fedora, OpenSUSE, CentOS, UBuntu etc. Most of them are available free of charges though you can have their enterprise versions by paying a nominal license fee.

  3. MacOS This is again a kind of Unix operating system developed and marketed by Apple Inc. since 2001.

  4. iOS This is a mobile operating system created and developed by Apple Inc. exclusively for its mobile devices like iPhone and iPad etc.

  5. Android This is a mobile Operating System based on a modified version of the Linux kernel and other open source software, designed primarily for touchscreen mobile devices such as smartphones and tablets.

其他一些古老却流行的操作系统包括 Solaris、VMS、OS/400、AIX、z/OS 等。

Some other old but popular Operating Systems include Solaris, VMS, OS/400, AIX, z/OS, etc.

Operating System - Functions

简单来说,以下是操作系统的一些重要功能,我们将在后续章节中详细介绍:

To brief, Following are some of important functions of an operating System which we will look in more detail in upcoming chapters:

  1. Process Management

  2. I/O Device Management

  3. File Management

  4. Network Management

  5. Main Memory Management

  6. Secondary Storage Management

  7. Security Management

  8. Command Interpreter System

  9. Control over system performance

  10. Job Accounting

  11. Error Detection and Correction

  12. Coordination between other software and users

  13. Many more other important tasks

Operating Systems - History

多年来,操作系统一直在不断发展。20 世纪 50 年代,计算机仅限于一次运行一个程序,如计算器,但在随后的几十年中,计算机开始包含越来越多的软件程序,有时称为库,这构成了当今操作系统的基础。

Operating systems have been evolving through the years. In the 1950s, computers were limited to running one program at a time like a calculator, but later in the following decades, computers began to include more and more software programs, sometimes called libraries, that formed the basis for today’s operating systems.

第一个操作系统是由通用汽车公司于 1956 年创建的,用于运行单台 IBM 大型计算机,其名称为 IBM 704。IBM 是第一家在 20 世纪 60 年代为其计算机开发操作系统并在其中分发操作系统的计算机制造商。

The first Operating System was created by General Motors in 1956 to run a single IBM mainframe computer, its name was the IBM 704. IBM was the first computer manufacturer to develop operating systems and distribute them in its computers in the 1960s.

以下是关于评估操作系统的几个事实:

There are few facts about Operating System evaluation:

  1. Stanford Research Institute developed the oN-Line System (NLS) in the late 1960s, which was the first operating system that resembled the desktop operating system we use today.

  2. Microsoft bought QDOS (Quick and Dirty Operating System) in 1981 and branded it as Microsoft Operating System (MS-DOS). As of 1994, Microsoft had stopped supporting MS-DOS.

  3. Unix was developed in the mid-1960s by the Massachusetts Institute of Technology, AT&T Bell Labs, and General Electric as a joint effort. Initially it was named MULTICS, which stands for Multiplexed Operating and Computing System.

  4. FreeBSD is also a popular UNIX derivative, originating from the BSD project at Berkeley. All modern Macintosh computers run a modified version of FreeBSD (OS X).

  5. Windows 95 is a consumer-oriented graphical user interface-based operating system built on top of MS-DOS. It was released on August 24, 1995 by Microsoft as part of its Windows 9x family of operating systems.

  6. Solaris is a proprietary Unix operating system originally developed by Sun Microsystems in 1991. After the Sun acquisition by Oracle in 2010 it was renamed Oracle Solaris.

Why to Learn Operating System

如果您渴望成为一名优秀的计算机程序员,强烈建议您深入了解操作系统的工作原理。这提供了理解如何将数据确切地保存在磁盘中、不同的进程如何被创建并被 CPU 调度运行、如何与不同的 I/O 设备和端口交互的机会。

If you are aspiring to become a Great Computer Programmer then it is highly recommended to understand how exactly an Operating System works inside out. This gives opportunity to understand how exactly data is saved in the disk, how different processes are created and scheduled to run by the CPU, how to interact with different I/O devices and ports.

有许多底层概念帮助程序员设计和开发可扩展的软件。底线是,如果没有对操作系统概念的很好理解,不能认为某人是一位优秀的计算机 Application Software 开发人员,而且甚至无法想象有人在深入了解操作系统之前成为 System Software 开发人员。

There are various low level concepts which help a programmer to Design and Develop scalable softwares. Bottom line is without a good understanding of Operating System Concepts, it can’t be assumed someone to be a good Computer Application Software developer, and even it is unimaginable imagine someone to become a System Software developer without knowing Operating System in-depth.

如果您是一名大一新生并申请在 Google、Microsoft、Amazon、IBM 等任何标准公司中担任工作,那么很有可能您会被询问有关操作系统概念的问题。

If you are a fresher and applying for a job in any standard company like Google, Microsoft, Amazon, IBM etc then it is very much possible that you will be asked questions related to Operating System concepts.

Target Audience

此教程已为计算机科学专业人员和学生编写,特别是 BCA、MCA、B.Tech、M.Tech 工程专业学生,旨在帮助他们了解与操作系统相关的基础到高级概念。操作系统是每个教授计算机科学的大学的核心概念之一,并且这一科目在考试中举足轻重。

This tutorial has been prepared for the Computer Science Professionals and Students specially for BCA, MCA, B.Tech, M.Tech Engineering Students to help them understand the basic to advanced concepts related to an Operating System in general. Operating System is one of the core concepts in every University teaching Computer Science and this subject has a lot of weight from exams point of view.

Prerequisites

在您开始使用本教程学习操作系统之前,我们假设您已经了解计算机基础知识,例如什么是计算机硬件、CPU、主存储器、辅助存储器、设备、文件等。如果您不了解这些概念,将很难理解有关操作系统相关的不同内容,因此強烈建議您在嘗試學習操作系统之前先通讀我們的 Computer Fundamentals Tutorial

Before you start learning Operating System using this tutorial, we are making an assumption that you are already aware of Computer Fundaments like What is Computer Hardware, CPU, Primary Memory, Secondary Memory, Devices, Files etc. If you are not already aware of these concepts then it will be difficult to understand various concepts related to Operating System and so it is highly recommended to go through our Computer Fundamentals Tutorial before attempting to learn Operating System.

Frequently Asked Questions about Operating System

关于操作系统有一些非常常见的问题 (FAQ),本部分试图简要回答它们。

There are some very Frequently Asked Questions(FAQ) about Operating System, this section tries to answer them briefly.