




































































Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
Lecture notes OP system
Typology: Lecture notes
1 / 76
This page cannot be seen from the preview
Don't miss anything!





































































On special offer
Vilnius Gediminas Technical University
Jelena Mamčenko
Code FMITB Course title Operating Systems Course volume 4,0 cr. (6,00 ECTS cr.) Teaching methods (Full-time, daytime studies): Lectures - 32 h per semestre Laboratory works - 32 h per semestre Individual work - 96 h per semestre Assesment - Examination Course aim: Understandig of Operating System's functions. Course description: Concept of operating system. Control the activities and resourses of computer. Interpreting comands. Coordinating activities. Operating systems MS-DOS, OS/2, UNIX. Networking.
1 Introduction Modern general-purpose computers, including personal computers and mainframes, have an operating system to run other programs, such as application software. Examples of operating systems for personal computers include Microsoft Windows, Mac OS (and Darwin), Unix, and Linux. The lowest level of any operating system is its kernel. This is the first layer of software loaded into memory when a system boots or starts up. The kernel provides access to various common core services to all other system and application programs. These services include, but are not limited to: disk access, memory management, task scheduling, and access to other hardware devices. As well as the kernel, an operating system is often distributed with tools for programs to display and manage a graphical user interface (although Windows and the Macintosh have these tools built into the operating system), as well as utility programs for tasks such as managing files and configuring the operating system. They are also often distributed with application software that does not relate directly to the operating system's core function, but which the operating system distributor finds advantageous to supply with the operating system. The delineation between the operating system and application software is not precise, and is occasionally subject to controversy. From commercial or legal points of view, the delineation can depend on the contexts of the interests involved. For example, one of the key questions in the United States v. Microsoft antitrust trial was whether Microsoft's web browser was part of its operating system, or whether it was a separable piece of application software. Like the term "operating system" itself, the question of what exactly should form the "kernel" is subject to some controversy, with debates over whether things like file systems should be included in the kernel. Various camps advocate microkernels, monolithic kernels, and so on. Operating systems are used on most, but not all, computer systems. The simplest computers, including the smallest embedded systems and many of the first computers did not have operating systems. Instead, they relied on the application programs to manage the minimal hardware themselves, perhaps with the aid of libraries developed for the purpose. Commercially-supplied operating systems are present on virtually all modern devices described as computers, from personal computers to mainframes, as well as mobile computers such as PDAs and mobile phones.
Today Command line interface (or CLI) operating systems can operate using only the keyboard for input. Modern OS's use a mouse for input with a graphical user interface (GUI) sometimes implemented as a shell. The appropriate OS may depend on the hardware architecture, specifically the CPU, with only Linux and BSD running on almost any CPU. Windows NT has been ported to other CPUs, most notably the Alpha, but not many. Since the early 1990s the choice for personal computers has been largely limited to the Microsoft Windows family and the Unix-like family, of which Linux and Mac OS X are becoming the major choices. Mainframe computers and embedded systems use a variety of different operating systems, many with no direct connection to Windows or Unix, but typically more similar to Unix than Windows.
Unix-like The Unix-like family is a diverse group of operating systems, with several major sub- categories including System V, BSD, and Linux. The name "Unix" is a trademark of The Open Group which licenses it for use to any operating system that has been shown to conform to the definitions that they have cooperatively developed. The name is commonly used to refer to the large set of operating systems which resemble the original Unix. Unix systems run on a wide variety of machine architectures. They are used heavily as server systems in business, as well as workstations in academic and engineering environments. Free software Unix variants, such as Linux and BSD, are increasingly popular. They are used in the desktop market as well, for example Ubuntu, but mostly by hobbyists. Some Unix variants like HP's HP-UX and IBM's AIX are designed to run only on that vendor's proprietary hardware. Others, such as Solaris, can run on both proprietary hardware and on commodity x86 PCs. Apple's Mac OS X, a microkernel BSD variant derived from NeXTSTEP, Mach, and FreeBSD, has replaced Apple's earlier (non-Unix) Mac OS. Over the past several years, free Unix systems have supplanted proprietary ones in most instances. For instance, scientific modeling and computer animation were once the province of SGI's IRIX. Today, they are dominated by Linux-based or Plan 9 clusters. The team at Bell Labs who designed and developed Unix went on to develop Plan 9 and Inferno, which were designed for modern distributed environments. They had graphics built-in, unlike Unix counterparts that added it to the design later. Plan 9 did not become popular because, unlike many Unix distributions, it was not originally free. It has since been released under Free Software and Open Source Lucent Public License, and has an expanding community of developers. Inferno was sold to Vita Nuova and has been released under a GPL/MIT license.
Microsoft Windows The Microsoft Windows family of operating systems originated as a graphical layer on top of the older MS-DOS environment for the IBM PC. Modern versions are based on the newer Windows NT core that first took shape in OS/2 and borrowed from OpenVMS. Windows runs on 32-bit and 64-bit Intel and AMD computers, although earlier versions also ran on the DEC Alpha, MIPS, and PowerPC architectures (some work was done to port it to the SPARC architecture). As of 2004, Windows held a near-monopoly of around 90% of the worldwide desktop market share, although this is thought to be dwindling due to the increase of interest focused on open source operating systems. [1] It is also used on low-end and mid-range servers, supporting applications such as web servers and database servers. In recent years, Microsoft has spent significant marketing
and R&D money to demonstrate that Windows is capable of running any enterprise application (see the TPC article).
Other Mainframe operating systems, such as IBM's z/OS, and embedded operating systems such as VxWorks, eCos, and Palm OS, are usually unrelated to Unix and Windows, except for Windows CE, Windows NT Embedded 4.0 and Windows XP Embedded which are descendants of Windows, and several *BSDs, and Linux distributions tailored for embedded systems. OpenVMS from Hewlett-Packard (formerly DEC), is still under active development. Older operating systems which are still used in niche markets include the Windows-like OS/2 from IBM; Mac OS, the non-Unix precursor to Apple's Mac OS X; BeOS; RISC OS; and AmigaOS. Research and development of new operating systems continues. GNU HURD is designed to be backwards compatible with Unix, but with enhanced functionality and a microkernel architecture. Microsoft Singularity is a research project to develop an operating system with better memory protection.
3 A history of personal computers A personal computer (PC) is usually a microcomputer whose price, size, and capabilities make it suitable for personal usage. The term was popularized by IBM marketing.
Time share "terminals" to central computers were sometimes used before the advent of the PC. (A smart terminal — televideo ASCII character mode terminal made around 1982.)
Before their advent in the late 1970s to the early 1980s, the only computers one might have used if one were privileged were "computer-terminal based" architectures owned by large institutions. In these, the technology was called "computer time share systems", and used minicomputers and main frame computers. These central computer systems frequently required large rooms — roughly, a handball-court-sized room could hold two to three small minicomputers and its associated peripherals, each housed in cabinets much the size of three refrigerators side by side (with blinking lights and tape drives). In that era, mainframe computers occupied whole floors; a big hard disk was a mere 10–20 Megabytes mounted on a cabinet the size of a small chest-type freezer. Earlier PCs were generally called desktop computers, and the slower Pentium-based personal computer of the late 1990s could easily outperform the advanced minicomputers of that era. Since the terms "personal computer" and "PC" have been introduced to vernacular language, their meanings and scope have changed somewhat. The first generations of personal microcomputers were usually sold as kits or merely instructions, and required a somewhat skilled person to assemble and operate them. These were usually called microcomputers, but personal computer was also used. Later generations were sometimes interchangeably called by the names
In the January 3, 1983 issue of Time magazine the personal computer was named the "Machine of the Year" or its Person of the Year for 1982. During the 1990s, the power of personal computers increased radically, blurring the formerly sharp distinction between personal computers and multi- user computers such as mainframes. Today higher-end computers often distinguish themselves from personal computers by greater reliability or greater ability to multitask, rather than by brute CPU ability.
Uses Personal computers are normally operated by one user at a time to perform such general purpose tasks as word processing, internet browsing, e-mail and other digital messaging, multimedia playback, video game play, computer programming, etc. Other more specific functions usually performed with the help of a PC include working, teleworking, learning, researching, printing, online banking, online shopping and dealing online with public sector institutions and services. The user of a modern personal computer may have significant knowledge of the operating environment and application programs, but is not necessarily interested in programming nor even able to write programs for the computer. Therefore, most software written primarily for personal computers tends to be designed with simplicity of use, or "user-friendliness" in mind. However, the software industry continuously provide a wide range of new products for use in personal computers, targeted at both the expert and the non-expert user.
4 Configuration
Exploded view of a modern personal computer:
Most personal computers are standardized to the point that purchased software is expected to run with little or no customization for the particular computer. Many PCs are also user- upgradable, especially desktop and workstation class computers. Devices such as main memory, mass storage, even the motherboard and central processing unit may be easily replaced by an end user. This upgradeability is, however, not indefinite due to rapid changes in the personal computer industry. A PC that was considered top-of-the-line five or six years prior may be impractical to upgrade due to changes in industry standards. Such a computer usually must be totally replaced once it is no longer suitable for its purpose. This upgrade and replacement cycle is partially related to new releases of the primary mass-market operating system, which tends to drive the acquisition of new hardware and tends to obsolete previously serviceable hardware (see planned obsolescence). The hardware capabilities of personal computers can sometimes be extended by the addition of expansion cards connected via an expansion bus. Some standard peripheral buses often used for adding expansion cards in personal computers as of 2005 are PCI, AGP (a high-speed PCI bus dedicated to graphics adapters), and PCI Express. Most personal computers as of 2005 have multiple physical PCI expansion slots. Many also include an AGP bus and expansion slot or a PCI Express bus and one or more expansion slots, but few PCs contain both buses.
5 Display A computer display (also known as a computer monitor, computer screen, or computer video display) is a device that can display signals generated by a computer as images on a screen. There are many types of monitors, but they generally conform to display standards. Once an essential component of computer terminals, computer displays have long since become standardised peripherals in their own right.
6 Motherboard The motherboard (or mainboard) is the primary circuit board for a personal microcomputer. Many other components connect directly or indirectly to the motherboard. Motherboards usually contain one or more CPUs, supporting circuitry and ICs for CPU operation, main memory, and facilities for initial setup of the computer immediately after being powered on (often called boot firmware or a BIOS). In many portable and embedded personal computers, the motherboard houses nearly all of the PC's core components. Often a motherboard will also contain one or more peripheral buses and physical connectors for expansion purposes. Sometimes a secondary daughter board is connected with the motherboard to provide further expandability or to satisfy space constraints.
7 Central processing unit The central processing unit, or CPU, is the part of the computer that executes software programs, including the operating system. Nearly all PCs contain a type of CPU known as a microprocessor. The microprocessor often plugs into the motherboard using one of many different types of sockets. IBM PC compatible computers use an x86-compatible processor, usually made by Intel, AMD, VIA Technologies or Transmeta. Apple Macintosh processors were based on the Power PC (a RISC architecture) but as of 2005, Apple has used x86 compatible processors from Intel.
of time. A particular location in storage is selected by its physical memory address. That address remains the same, no matter how the particular value stored there changes.
8.1 Technology and history Today, primary storage is typically random access memory, a type of semiconductor memory. Over the history of computing hardware, a variety of technologies have been used for primary storage. Some early computers used mercury delay lines, in which a series of acoustic pulses were sent along a tube filled with mercury. When the pulse reached the end of the tube, the circuitry detected whether the pulse represented a binary 1 or 0 and caused the oscillator at the beginning of the line to repeat the pulse. Other early computers stored primary memory on rapidly rotating magnetic drums. Modern primary storage devices include:
9 Expansion card
Fitting an expansion card into a motherboard An expansion card in computing is a printed circuit board that can be inserted into an expansion slot of a computer motherboard to add additional functionality to a computer system. One edge of the expansion card holds the contacts that fit exactly into the slot. They establish the electrical contact between the electronics (mostly integrated circuits) on the card and on the motherboard. Connectors mounted on the bracket allow the connection of external devices to the card. Depending on the form factor of the motherboard and case, around one to seven expansion cards can be added to a computer system. There are also other factors involved in expansion card capacity. For example, some expansion cards need two slots like some NVidia GeForce FX graphics cards and there is often a space left to aid cooling on some high-end cards.
9.1 History of the expansion card The first microcomputer to feature a slot-type expansion card bus was the Altair 8800, developed 1974-1975. Initially, implementations of this bus were proprietary (such as the Apple II and Macintosh), but by 1982 manufacturers of Intel 8080/Zilog Z80-based computers running CP/M had settled around the S-100 standard. IBM introduced the XT bus with the first IBM PC in
video acceleration solution. Though termed a bus, AGP supports only a single card at a time. Both of these technologies are now slated to be replaced by PCI-Express, beginning in 2005. This latest standard, approved in 2004, implements the logical PCI protocol over serial communication interface.
Expansion slot standards
Expansion card types
10 Power supply A power supply (sometimes known as a power supply unit or PSU) is a device or system that supplies electrical or other types of energy to an output load or group of loads. The term is most commonly applied to electrical energy supplies. The complete range of power supplies is very broad, and could be considered to include all forms of energy conversion from one form into another. Conventionally though, the term is usually confined to electrical or mechanical energy supplies. Constraints that commonly affect power supplies are the amount of power they can supply, how long they can supply it for without needing some kind of refueling or recharging, how stable their output voltage or current is under varying load conditions, and whether they provide continuous power or pulses. The voltage regulation of power supplies is done by incorporating circuitry to tightly control the output voltage and/or current of the power supply to a specific value. The specific value is closely maintained despite variations in the load presented to the power supply's output, or any reasonable voltage variation at the power supply's input.
it is connected to an electrical outlet as high voltages may be present even while the unit is switched off. In desktop computers, the power supply is a small (PSU) box inside the computer; it is an important part of the computer because it provides electrical power in a form that is suitable for every other component inside or attached to the computer in order for it to work. If only a small voltage is needed, the mains power needs to be transformed to a suitable level in order for the component to work. In portable computers there is usually an external power supply that produces low voltage DC power from a mains electrical supply (typically a standard AC wall outlet). Circuitry inside the portable computer uses this transformed power to charge the battery as needed, in addition to providing the various voltages required by the other components of the portable computer.
11.1 Domestic mains adaptors
A power supply (or in some cases just a transformer) that is built into the top of a plug is known as a wall wart, power brick, or just power adapter.
11.2 Linear power supply A simple AC powered linear power supply uses a transformer to convert the voltage from the wall outlet to a lower voltage. A diode circuit (generally either a single diode or an array of diodes called a diode bridge but other configurations are possible) then rectifies the AC voltage to pulsating DC. A capacitor smooths out most of the pulsating of the rectified waveform to give a DC voltage with some ripple. Finally depending on the requirements of the load a linear regulator may be used to reduce the voltage to the desired output voltage and remove the majority of the remaining ripple. It may also provide other features such as current limiting.
11.3 Switched-mode power supply In a switched-mode power supply the incoming power is passed through a transistor and transformer network that switches on and off thousands to millions of times per second. This means that a smaller, less expensive, lighter transformer can be used, because the voltage is being made to alternate faster, and thus a smaller magnetic core can be used. Switching power supplies can be used as DC to DC converters. In this application, the power supply is designed to accept a limited range DC input and then output a different DC voltage. This is particularly useful in portable devices, as well as power distribution in large electronic equipment. A transformerless switching power supply that outputs a voltage higher than its input voltage is typically called a boost converter. A transformerless switching power supply that outputs a voltage lower than its input voltage is typically called a buck converter. These transformerless switching power supplies use an inductor as the primary circuit element in converting the voltage. Circuitry is used to pass current through the inductor to store a certain amount of electrical energy as a magnetic field. The current flow is then stopped, and the magnetic field collapses causing the stored energy to be released as current again. This is done rapidly (up to millions of times per second). By carefully metering the amount of energy stored in the inductor, the current released by the inductor can be regulated thus allowing the output voltage to be tightly regulated. A switching power supply incorporating a transformer can provide many output voltages simultaneously, and is typically called a flyback converter. Switching power supplies are typically very efficient if well designed, and therefore waste very little power as heat. Because of these efficiencies, they are typically much smaller and lighter than an equivalently rated linear supply.
Power conversion The term "power supply" is sometimes restricted to those devices that convert some other form of energy into electricity (such as solar power and fuel cells and generators). A more
accurate term for devices that convert one form of electric power into another form of electric power (such as transformers and linear regulators) is power converter. Uses in aviation The most exotic power supplies are used in aviation to enable reliable restarting of stalled engines. In jet transports, an engine is restarted from the power produced by the 400 Hz, three-phase AC generators attached to the shafts of the other engine(s). Most of the starting torque generated by the engine's motor/generator is provided by the current at the peaks of the AC waveform. If the aircraft electronics used simple rectifying power supplies, they would use current only from these peaks, since the diodes conduct only during the voltage peaks where the input voltage is higher than the output voltage. This could prevent the pilot from restarting an engine in an emergency. Therefore, aircraft power supplies take energy evenly from all parts of the AC waveform. this is done by using a switching power supply technique called "power factor correction" which creates a balanced current draw over the entire AC waveform.
12 Optical disc In computing, sound reproduction, and video, an optical disc is flat, circular, usually polycarbonate disc whereon data is stored. This data is generally accessed when a special material on the disc (often aluminum) is illuminated with a laser diode. David Paul Gregg developed an analog optical disk for recording video and patented it in 1961 and 1969 (U.S. patent 3430966). Of special interest is U.S. 4,893,297, first filed in 1968 and issued in 1990, so that it will be a source of royalty income for Pioneer’s DVA until 2007. It encompasses systems such as CD, DVD, and even Blu-ray Disc. Gregg's company, Gauss Electrophysics, was acquired, along with Gregg's patents, by MCA in the early 1960s. Parallel, and probably inspired by the developments in the U.S., a small group of physicists started their first optical videodisc experiments at Philips Research in Eindhoven, The Netherlands in 1969. In 1975, Philips and MCA decided to join forces. In 1978, much too late, the long waited laserdisc was introduced in Atlanta. MCA delivered the discs and Philips the players. It turned out to be a total technical and commercial failure, and quite soon the Philips/MCA cooperation came to an end. In Japan and the U.S., Pioneer has been successful with the videodisc till the advent of DVD. Philips and Sony formed a consortium in 1979 to develop a digital audio disc, which resulted in the very successful introduction of the compact disc in 1983. The promotion of standardised optical storage is undertaken by the Optical Storage Technology Association (OSTA). The information on an optical disc is stored sequentially on a continuous spiral track from the innermost track to the outermost track.
12.1 First-generation optical discs Optical discs were initally used for storing music and software. The Laserdisc format stored analog video, but it fought an uphill battle against VHS.
12.2 Second-generation optical discs These discs were invented roughly in the 1990s. Second-generation optical discs were created to store large amounts of data, including TV-quality digital video.
A 104-key PC US English QWERTY keyboard layout Roughly 50% of all keyboard keys produce letters, numbers or signs (characters). Other keys can produce actions when pressed, and other actions are available by simultaneously pressing more than one action key. 15 Mouse (computing)
Fig. 1. Operating mechanical mouse
Operating a mechanical mouse (Fig. 2). 1: Moving the mouse turns the ball. 2: X and Y rollers grip the ball and transfer movement. 3: Optical encoding disks include light holes. 4: Infrared LEDs shine through the disks. 5: Sensors gather light pulses to convert to X and Y velocities.
Fig. 2. The first computer mouse
A mouse is a handheld pointing device for computers, being a small object fitted with one or more buttons and shaped to sit naturally under the hand. The underside of the mouse houses a device that detects the mouse's motion relative to the flat surface on which it moves. The mouse's 2D motion is typically translated into the motion of a pointer on the display. It is called a mouse primarily because the cord on early models resembled the rodent's tail, and also because the motion of the pointer on the screen can be mouse-like (Fig. 2).
16 Main memory A PC's main memory place (or primary storage) is fast storage space that is directly accessible by the CPU. It is generally used for storing relatively short-term data needed for software execution. Main memory is usually much faster than mass storage devices like hard disks or optical discs, but usually cannot retain data for more than a few fractions of a second without power and is more expensive. Therefore, it is not generally suitable for long-term or archival data storage. As with the CPU, most PCs use some form of semiconductor random access memory such as DRAM or SRAM as their primary storage.
17 Hard disk drive The disk drives use a sealed head/disk assembly (HDA) which was first introduced by IBM's "Winchester" disk system. The use of a sealed assembly allowed the use of positive air pressure to drive out particles from the surface of the disk, which improves reliability. If the mass storage controller provides for expandability, a PC may also be upgraded by the addition of extra hard disk or optical drives. For example, DVD-ROMs, CD-ROMs, and various optical disc recorders may all be added by the user to certain PCs. Standard internal storage device interfaces are ATA, Serial ATA, SCSI, and CF+ Type II in 2005.
18 Graphics - Video card The graphics card - otherwise called a graphics adapter, video adapter, or video card - processes and renders the graphics output from the computer to the VDU or computer monitor and is an essential part of the modern computer. On older and budget models graphics cards tended to be integrated with the motherboard but, more commonly, they are supplied in PCI, AGP, or PCI Express format. Graphic cards are also the most glamorised computer component as it is the component which creates all the visual effects on the computer which is essential for playing games.
Laptop computers A laptop computer or simply laptop (also notebook computer or notebook) is a small personal computer designed for mobility. Usually all of the peripherals needed to operate the laptop are built in to a single unit. Most laptops contain batteries to facilitate operation without a readily available electrical outlet.
Non IBM-compatible personal computers Though many personal computers are IBM PC compatible using either Microsoft Windows or closed and open-source Unix-likes such as Linux, a number of other personal computer types are also popular. A leading alternative to the IBM PC is the Apple Macintosh, a combination of proprietary hardware and operating system. The Macintosh orignally used the Motorola 68000 series, then shifted to the IBM and Motorola PowerPC processors. In January 2006, Apple shifted its architecture to the same Intel chip found in IBM compatibles, allowing their computers to run Apple's own Mac OS X as well as other IBM PC Compatible Operating Systems. Further PC and PW (Personal Workstation) types through time: