Αρχική ΑΕΠΠ - Δομές Δεδομένων Λειτουργικά Συστήματα Δίκτυα Υπολογιστών ΙΙ Βάσεις Δεδομένων Παιδαγωγικά - Διδακτική
Εισαγωγή στα Λ.Σ. Βασικές Δομές Η/Υ Βασικές Δομές Λ.Σ
Διεργασίες Χρονοπρογραμματισμός Συγχρονισμός
Μονοπρογραμματισμός Εναλλαγή Εικονική Μνήμη Κατάτμηση
True/False: An operating system can be viewed as “resource allocator” to control various I/O devices and user programs.
True
What is the fundamental goal of computer systems?
To execute user programs and solve user problems.
Define operating systems in terms of what they do.
Their primary goal is convenience of the user; the secondary goal is efficient operation and allocation of all resources.
Describe how the earliest computers were used.
The programmer himself operated the computer by using switches. He had to sign up for free time.
What problems were involved in these earliest computers?
The user had to guess the amount of time needed to complete his job, fairly accurately, to avoid wasting machine time, and still allow enough time to complete the job.
What software was added to increase user efficiency?
Libraries of common functions, device drivers, assembly language, compilers.
What effect did adding I/O devices have on software?
Creation of software libraries shared by all users, especially for input–output subroutines.
What factors contributed to the setup time for a job? List them.
Note: On some systems, the loader had to be reloaded after many of the above steps.
What is a simple batch system?
A professional computer operator (or machine) groups jobs by characteristics and runs groups of similar jobs together, eff5ciently.
Why use simple batch systems, in preference to early systems?
Less setup time, and thus less idle time of the computer.
What is “automatic job sequencing”?
System proceeds from one job to the next without human intervention.
Why have automatic job sequencing?
To avoid the delays inherent in having the operator changing jobs, and doing things manually.
What is the purpose of the “resident monitor”?
To perform orderly and eff5cient automatic job sequencing, regardless of errors that might arise.
What were control cards used for?
To let monitor know what resources are needed for current job, such as compiler, linker, data, etc., when to use them, and with which file; and to tell monitor when it reaches end of job.
List parts of the monitor.
Control card interpreter, device drivers, loader.
Compare speeds of various I/O devices, in characters/second.
humans 0.5 to 5 characters/second paper tape 10 characters/second cards 1600 characters/second magnetic tape 160,000 characters/second.
Describe two kinds of off-line operations.
Describe two approaches to off-line processing.
What is device independence?
The feature of systems that allows one input device to be replaced by another without changes in the users’ programs. Similarly with output. Thus, an old model card reader can be replaced with a new model; the old device driver programs are replaced by new ones; user programs need not be changed (though they may need to be relinked). Note: Many students respond that it is the ability to use different devices. This is false. You can write a FORTRAN II program to read cards and print to a line printer, two different devices; yet this does not imply device independence.
What were the advantages of off-line operations?
How have disk systems helped solved problems inherent in off-line systems?
Off-line systems use magnetic tape. The system cannot read data from one end of the tape while the card reader writes data on the other end; it takes about 5 minutes to rewind the tape fully. With disks, it takes only milliseconds to alternate from the portion of the disk used for input and the portion for output.
What is spooling?
An acronym for “Simultaneous Peripheral Operation On-Line.” It uses the disk as a large buffer for outputting data to line printers and other devices (like microfilm). It can also be used for input, but is generally used for output. Its main use is to prevent two users from alternately printing lines to the line printer on the same page, getting their output completely mixed together. It also helps in reducing idle time and overlapped I/O and CPU.
How do I/O-bound and CPU-bound programs differ?
In I/O-bound programs, the CPU remains idle much of the time. In CPU-bound programs, the I/O processor remains idle. Note: I/O is never “faster” than CPU.
What is multiprogramming?
In multiprogramming, several programs are in memory concurrently; the system switches among the programs for ef?cient processing, and minimal idle time. Note: Many students claim multiprogramming “always” keeps CPU and I/O devices busy; this is false; what is the computer to do at 3 AM Sunday morning, when there’s no job to run?
Define batch systems in terms of interaction.
They are essentially devoid of interaction between user and program. All problems must be anticipated, and can’t be corrected on-line.
In what ways are batch systems inconvenient for users?
Users can’t interact with their jobs to fix problems. They must anticipate problems or else debugging could be a mess with machine-language dumps. There may also be long turnaround times.
What is time-sharing?
Using scheduling and multiprogramming to provide an economical interactive system of two or more users.
What are the main advantages of a time-share system?
Interaction with computer while program is running, short response times (usually less than 10 seconds).
How is time-sharing usually implemented?
Each user is given a brief time-slice for her job, in round-robin fashion. Her job continues until the time-slice ends. Then her job stops, until it is her turn again.
How do MULTICS and UNIX differ?
What is a multiprocessor system?
A system with two or more CPUs.
What is a master/slave processor system?
A master computer controls the actions of various slave computers.
What is a real-time system?
A system used to control a dedicated application.
How does a real-time system differ from time-share?
In time-sharing, fast response is desirable, but not required. In real-time systems, processing must be completed within certain time constraints appropriate for the system.
List several examples of real-time systems.
What are the three main purposes of an operating system?
There are several possible purposes of an operating system:
List the four steps that are necessary to run a program on a completely dedicated machine.
An extreme method of spooling, known as staging a tape, is to read the entire contents of a magnetic tape onto disk before using it. Discuss the main advantage of such a scheme.
No I/O is needed while the data is being processed, so staging is more simple than spooling. All of the data are on-line before they are needed so a process can run at full speed. The disadvantage is that more time is spent, before the process starts, in loading the data, and more disk space is consumed in storing the entire tape contents.
In a multiprogramming and time-sharing environment, several users share the system simultaneously. This situation can result in various security problems.
Explain your answer.
What is the main advantage of multiprogramming?
Multiprogramming makes efficient use of the CPU by overlapping the demands for the CPU and its I/O devices from various users. It attempts to increase CPU utilization by always having something for the CPU to execute.
What are the main differences between operating systems for mainframe computers and personal computers?
Personal computer operating systems are not concerned with fair use, or maximal use, of computer facilities. Instead, they try to optimize the usefulness of the computer for an individual user, usually at the expense of efficiency. Consider how many CPU cycles are used by graphical user interfaces (GUIs). Mainframe operating systems need more complex scheduling and I/O algorithms to keep the various system components busy.
Define the essential properties of the following types of operating systems: Batch Interactive Time sharing Real time Distributed.
We have stressed the need for an operating system to make efficient use of the computing hardware. When is it appropriate for the operating system to forsake this principle and to “waste” resources? Why is such a system not really wasteful?
Single-user systems should maximize use of the system for the user. A GUI might “waste” CPU cycles but it optimizes the user’s interaction with the system.
Under what circumstances would a user be better off using a time-sharing system, rather than a personal computer or single-user workstation?
When there are few other users, the task is large, and the hardware is fast, timesharing makes sense. The full power of the system can be brought to bear on the user’s problem. The problem can be solved faster than on a personal computer. Another case is when there are lots of other users needing resources at the same time. A personal computer is best when the job is small enough to be executed reasonably on it, and when performance is sufficient to execute the program to the user’s satisfaction.
Describe the differences between symmetric and asymmetric multiprocessing. What are three advantages and one disadvantage of multiprocessor systems?
Symmetric multiprocessing treats all processors as equals, and I/O can be processed on any CPU. Asymmetric multiprocessing has one master CPU and the remainder CPUs are slaves. The master distributes tasks among the slaves, and I/O is usually done by the master only. Multiprocessors can save money, by not duplicating power supplies, housings, and peripherals. They can execute programs more quickly, and can have increased reliability. They are also more complex in both hardware and software than uniprocessor systems.
Why are distributed systems desirable?
Distributed systems can provide resource sharing, computation speedup, increased reliability, and the ability to communicate with remote sites.
What is the main difficulty that a programmer must overcome in writing an operating system for a real-time environment?
The main difficulty is keeping the operating system within the fixed time constraints of a real-time system. If the system does not complete a task in a certain time, it could cause a breakdown of the entire system it is running. Therefore when writing an operating system for a real-time system, the writer must be sure that his scheduling schemes don’t allow response time to exceed the time constraint.
Copyright 2008 - Άρης Φεργάδης