Lesson 1: Overview of Operating System
Lesson 1: Overview of Operating System
Operating System
User View—cont…
The user interface for mobile computers generally features a
touch screen, where the user interacts with the system by
pressing and swiping fingers across the screen rather than
using a physical keyboard and mouse. Many mobile devices
also allow users to interact through a voice recognition
interface, such as Apple’s Siri.
Some computers have little or no user view. For example,
embedded computers in home devices and automobiles may
have numeric keypads and may turn indicator lights on or off
to show status, but they and their operating systems and
applications are designed primarily to run without user
intervention.
Serial Processing
With the earliest computers, from the late 1940s to the
mid-1950s, the programmer interacted directly with the
computer hardware; there was no OS. These computers
were run from a console consisting of display lights, toggle
switches, some form of input device, and a printer.
Programs in machine code were loaded via the input
device (e.g., a card reader). If an error halted the program,
the error condition was indicated by the lights. If the
program proceeded to a normal completion, the output
appeared on the printer.
Time-Sharing Systems
Today, the requirement for an interactive computing facility can
be, and often is, met by the use of a dedicated personal
computer or workstation. That option was not available in the
1960s, when most computers were big and costly. Instead, time
sharing was developed.
Multiprogramming allows the processor to handle multiple batch
jobs at a time, multiprogramming can also be used to handle
multiple interactive jobs.
The technique is referred to as time sharing, because
processor time is shared among multiple users. In a time-
sharing system, multiple users simultaneously access the
system through terminals, with the OS interleaving the
execution of each user program in a short burst or quantum
of computation.
IT 311: Applied Operating System
The Evolution of Operating Systems
Operating-System Services
An operating system provides an environment for the execution
of programs. It makes certain services available to programs
and to the users of those programs.
One set of operating system services provides functions that
are helpful to the user:
User interface
Program execution
I/O operations
File-system manipulation
Communications
Error detection
Operating-System Services
Another set of operating-system functions exists not for helping
the user but rather for ensuring the efficient operation of the
system itself.
Resource allocation
Logging
Protection and security
System Calls
System calls provide an interface to the services made
available by an operating system. These calls are generally
available as functions written in C and C++, although certain
low-level tasks (for example, tasks where hardware must be
accessed directly) may have to be written using assembly-
language instructions.
Systems execute thousands of system calls per second.
Application developers design programs according to an
application programming interface(API).
Background
Microsoft initially used the name Windows in 1985, for an operating
environment extension to the primitive MS-DOS operating system,
which was a successful OS used on early personal computers. This
Windows/MS-DOS combination was ultimately replaced by a new
version of Windows, known as Windows NT, first released in 1993,
and intended for laptop and desktop systems. Although the basic
internal architecture has remained roughly the same since Windows
NT, the OS has continued to evolve with new functions and features.
The latest release at the time of this writing is Windows 10. Windows
10 incorporates features from the preceding desktop/laptop release,
Windows 8.1, as well as from versions of Windows intended for mobile
devices for the Internet of Things (IoT). Windows 10 also incorporates
software from the Xbox One system. The resulting unified Windows 10
supports desktops, laptops, smart phones, tablets, and Xbox One.
Architecture
The figure illustrates the overall structure of Windows. As
with virtually all operating systems, Windows separates
application-oriented software from the core OS software. The
latter, which includes the Executive, the Kernel, device
drivers, and the hardware abstraction layer, runs in kernel
mode. Kernel-mode software has access to system data and
to the hardware. The remaining software, running in user
mode, has limited access to system data.
Architecture
User-Mode Processes
Windows supports four basic types of user-mode processes:
• Special system processes: User-mode services needed to
manage the system, such as the session manager, the
authentication subsystem, the service manager, and the logon
process.
• Service processes: The printer spooler, the event logger, user-
mode components that cooperate with device drivers, various
network services, and many others. Services are used by both
Microsoft and external software developers to extend system
functionality, as they are the only way to run background user-
mode activity on a Windows system.
User-Mode Processes
Windows supports four basic types of user-mode processes:
• Environment subsystems: Provide different OS personalities
(environments). The supported subsystems are Win32 and POSIX.
Each environment subsystem includes a subsystem process
shared among all applications using the subsystem and dynamic
link libraries (DLLs) that convert the user application calls to ALPC
calls on the subsystem process, and/or native Windows calls.
• User applications: Executables (EXEs) and DLLs that provide the
functionality users run to make use of the system. EXEs and DLLs
are generally targeted at a specific environment subsystem;
although some of the programs that are provided as part of the OS
use the native system interfaces (NT API). There is also support for
running 32-bit programs on 64-bit systems.
Client/Server Model
Advantages of a client/server architecture include the
following:
1. It simplifies the Executive.
2. It improves reliability.
3. It provides a uniform means for applications to communicate with
services via RPCs without restricting flexibility.
4. It provides a suitable base for distributed computing.
Windows Objects
object-oriented concepts used by Windows are the
following:
• Encapsulation:
• Object class and instance:
• Inheritance:
• Polymorphism:
History
UNIX was initially developed at Bell Labs and became
operational on a PDP-7 in 1970. Work on UNIX at Bell
Labs, and later elsewhere, produced a series of versions
of UNIX. The first notable milestone was porting the UNIX
system from the PDP-7 to the PDP-11. This was the first
hint that UNIX would be an OS for all computers. The next
important milestone was the rewriting of UNIX in the
programming language C. This was an unheard-of
strategy at the time.
Description
The classic UNIX architecture can be pictured as in three
levels: hardware, kernel, and user.
The OS is often called the system kernel, or simply the kernel, to
emphasize its isolation from the user and applications. It interacts
directly with the hardware. It is the UNIX kernel that we will be
concerned with in our use of UNIX as an example in this book.
UNIX also comes equipped with a number of user services and
interfaces that are considered part of the system. These can be
grouped into the shell, which supports system calls from
applications, other interface software, and the components of the
C compiler (compiler, assembler, loader). The level above this
consists of user applications and the user interface to the C
compiler.
BSD
The Berkeley Software Distribution (BSD) series of
UNIX releases have played a key role in the
development of OS design theory. 4.xBSD is widely
used in academic installations and has served as the
basis of a number of commercial UNIX products. It is
probably safe to say that BSD is responsible for much
of the popularity of UNIX, and that most enhancements
to UNIX first appeared in BSD versions.
The latest version of the Macintosh OS, originally
known as OS X and now called MacOS, is based on
FreeBSD 5.0 and the Mach 3.0 microkernel.
Solaris 11
Solaris is Oracle’s SVR4-based UNIX release, with the
latest version being 11. Solaris provides all of the
features of SVR4 plus a number of more advanced
features, such as a fully preemptable, multithreaded
kernel, full support for SMP, and an object-oriented
interface to file systems. Solaris is one the most widely
used and most successful commercial UNIX
implementations.
History
Linux started out as a UNIX variant for the IBM PC (Intel
80386) architecture. Linus Torvalds, a Finnish student of
computer science, wrote the initial version. Torvalds
posted an early version of Linux on the Internet in 1991.
Since then, a number of people, collaborating over the
Internet, have contributed to the development of Linux, all
under the control of Torvalds. Because Linux is free and
the source code is available, it became an early alternative
to other UNIX workstations, such as those offered by Sun
Microsystems and IBM. Today, Linux is a full-featured
UNIX system that runs on virtually all platforms.
Modular Structure
Linux may be considered monolithic, its modular structure
overcomes some of the difficulties in developing and
evolving the kernel. The Linux loadable modules have two
important characteristics:
Dynamic linking: A kernel module can be loaded and linked into
the kernel while the kernel is already in memory and executing. A
module can also be unlinked and removed from memory at any
time.
Stackable modules: The modules are arranged in a hierarchy.
Individual modules serve as libraries when they are referenced by
client modules higher up in the hierarchy, and as clients when they
reference modules further down.