340 likes | 846 Views
Timesharing. The problem with batch multiprogramming systems is simply that they are batch!!! Once the programmer submits his job to the operator to execute, there is no interactions
E N D
Timesharing • The problem with batch multiprogramming systems is simply that they are batch!!! Once the programmer submits his job to the operator to execute, there is no interactions • With the development of disk file systems, the amount of direct input needed to execute a job drastically decreased. • Source programs and data could be prepared ahead of time and stored in files, and all that was needed to execute a job was a few lines of JCL. • This led to the idea that perhaps programmers could use a typewriter type device to directly enter these JCL instructions to the computer and receive results immediately providing a new kind of interactive computing. • However, putting the entire computer under the control of a single user was little better than older batch serial systems.
However if the multiprogramming concept could be extended to support multiple users at typewriters, then the computer could be kept busy. • Allowed multiple interactive users to share the computer simultaneously. Each user session is simply another process to be managed by the OS. • As with multiprogramming OSs, the CPU executes multiple “jobs” simultaneously by switching between them. Each user has at least one program loaded into memory and executing. • These processes consist of both user written application programs, and special system programs which provide a user interface through which a user can submit instructions directly to the OS. A program loaded into memory and executing is commonly referred to as a process.
The key to a time sharing OS, is that the CPU switches between tasks so frequently that interactive users can feel as if they have their own dedicated machine, and interact with each process as it executes. • This frequent switching is accomplished by assigning a short time limit called a time slice to each job. When a process begins execution, an internal timer is set to interrupt a job automatically when the time slice expires. Once interrupted each job waits for the other jobs to have a turn before finally receiving more service.
Time sharing OS’s are more complex than multiprogramming OS’s for the following reasons: • To obtain a reasonable response time switching between tasks must occur at a much faster rate. This may require jobs to be swapped in and out of memory more frequently. Additionally, with a large number of users this switching overhead could leave little time for useful work!!!! • Time sharing systems must provide an extensive file system, disk management facilities, mechanisms for job synchronization and communication. • Although time-sharing systems were demonstrated as early as 1960, they were expensive and difficult to build and didn’t become common until the 1970’s
CTSS • CTSS (Compatible Timesharing System), was developed by a government funded research group called Project MAC at MIT. • Ran on an IBM 7094 with specially modified hardware. • First demonstrated in 1961, and used at MIT until the mid 1970’s. • It established the effectiveness of the timesharing concept, and its impact on the productivity of programmers and users. • It also illustrated that although timesharing was workable, a great deal more time was spend by the OS switching between tasks than actually executing programs. With a large number of users this switching overhead could leave little time for other tasks. Faster computers with carefully designed supervisors were needed. • Additionally shared files and resources required the need to protect users from each other.
Multics • Also developed by Project Mac as a successor to CTSS • It was a large OS with many new features: • Segmented virtual memory: program memory is organized as a vector of vectors. Each vector is a segment, and each segment is a file. This allowed main memory and files to be treated uniformly. • The ability to load/link segments on demand • A hierarchical file system • I/O redirection • An innovative protection mechanism, in which protection domains are organized hierarchically into a cyclic ring structure. • It was written almost entirely in a high-level language which was a variant of PL/I.
OS History Part 2 Mini & Micro Computers
The development of Operating Systems for mini and micro computers paralleled that of mainframe systems, although at an excellerated pace. • We advanced from no operating system, to managing simple devices, single user systems, multi-programming, multi-user/multi-tasking.
AS early as 1955, several small scale computers were on the market priced at under $50,000, including the Burroughs E101, and Bendix 6-15. However, • They were large bulky machines with unreliable vacuum tubes. • Slow - several milliseconds for an arithmetic operation • Memory was limited to a few 1000 words • Had to be programmed in machine language with a very limited instruction set and NO OS of any type.
Programming followed an evolution similar to that of mainframes beginning by using front panel switches and display lights, followed by punched paper tape, and limited systems software.
Dec PDP series • An early Dominate player in the mini-computer market was Dec with their PDP series, in the early 1960’s. • The 12 bit PDP-8, which was priced under $18,000, became one of the best-selling computers of all time. This system introduced some features important for real-time applications including: • interrupts • a clock • direct memory access for high-speed I/O devices. These features made them ideal for controlling real time devices • Initially supplied with paper tape based software
By 1970, three important operating systems were available for DEC’s PDP-11. • RT-11: (RT stands for real time) small, simple, realtime, single user OS • Used for real time systems, process control, and data acquisition. • It provided a simple command interface • Normally executed one program at a time • It did not support preemptive multitasking, but a limited form of multiprogramming was provided via the capability of executing foreground/background jobs with a fixed priority, background jobs had the lowest priority . This allowed one process, not currently communicating with the user, to continue execution in the background while the user interacted with a different process in the foreground.
In early versions device drivers were built into the kernel at configuration time, but later versions allowed the device drivers to loaded separately. • It came with several programs including a text editor, a simple command interface “kmon”, and a batch processor. Tools for assembly language programs were provided, but at additional cost users could obtain versions of C, FORTRAN, Pascal and basic. • It also supported a simple and fast file system, with filenames limited to 6 characters, with a 3 character extension. All files were contiguous, (occupying consecutive blocks). Files could be read or written very quickly, as the smallest addressable unit of disk storage was 512 bytes. Writing files as blocks caused files to be created and deleted frequently, causing disk fragmentation.
RSTS: was a multi-user time sharing system, used primarily during the 1970’s and 1980’s. • The kernel was programmed in MACRO-11 assembly language. • It provided a basically text based command line interface (DCL), and supported a maximum of 128 terminals running a maximum of 63 jobs, depending on the underlying amount of memory and disk space. Users could also submit jobs to be run in a background batch mode. • A user logged on to a “logged-out” terminal by entering their user number and password. User numbers consisted of two parts a “project #” , “programmer #”. This is similar to Unix’s group id/user id. This allowed for file sharing within groups. • As with RT11- files were written and retrieved in blocks of 512 k. • Available programming languages: Basic plus, COBOL, FORTRAN, Pascal, Algol-60
RSX-11: The most advanced of the PDP-11 operating systems it was a real-time OS which became common in the late 1970’s and 1980’s, and supported: • A powerful command language • Hierarchical File system • Memory management, through memory overlays, which allows programs too big to fit into existing physical memory to be loaded in pieces. • Provided support for multiple users, and Multiprogramming
Unix • Developed by Ken Thomas and Dennis Ritchie for the PDP-7, at Bell Labs incorporating many of the concepts of MULTICS. • Their main goal was to create a convenient working environment for developing programs
Hierarchical file system • Interactive command interpreter called the shell, multiple versions of command interpreters exist, allowing individual users to use their interface of choice. • A File system which treats I/O devices as special cases of files. • Re-direction of I/O • Although the earliest version of Unix supported only a single user, that user could run multiple concurrent processes. Additionally the shell and the system supported the ability of for the output stream of one process to become the input stream of another (pipes).
Although the first versions of UNIX were written in assembly language, later almost all of UNIX was rewritten in C. • Its wide spread popularity can also be attributed to the fact that it was offered to universities at a nominal cost (or free) with complete source code.
Micro Computers • Personal computers first appeared in the 1970’s. • Operating systems for the PC benefited from the experiences of developing operating systems in the other areas. • However, during their first decade, the CPU’s in PCs lacked features necessary to protect the operating system from user programs. • Therefore, by necessity they were neither multi-user nor multitasking. • Also, from the beginning, since these computer systems were intended to be purchased and used by individuals, the primary goals of the operating systems focused on user convenience and responsiveness rather than maximizing CPU and peripheral utilization.
CP/M • CP/M was developed by Gary Kildall at Intel while working as a consultant to develop software for the 8080/85 microprocessor. Kildall developed a simplified version of PL/I called PL/M specifically designed for writing microprocessor system software. It was a simple single user operating system requiring a minimal 8-bit configuration: • A terminal using the ASCII character set • Intel 8080(8085) microprocessor • 16 k RAM • Minimal bootloader in ROM • One diskette drive. • CP/M consisted of 3 components: • Command processor: CCP: was a simple command line interface, patterned after RSTS for the PDP-11. Commands generally took the form of a keyword followed by a list of parameters, separated by spaces. Commands not recognized as part of the built-in commands were assumed to be transient user programs, which were located in the user area, loaded and passed any additional parameters from the command line. Transient programs were allowed to occupy memory space normally occupied by CP/M and when the application terminated, CP/M was reloaded. • Basic disk operating system: BDOS: Provided basic operations such as opening a file, output to console and printing. • Basic input/output system or BIOS: Provides low level operatins needed by the OS. Including reading and writing single characters to system consoles, reading or writing sectors of data from the disks. • It provided a floppy-disk based file system. With 8 character file names with 3character extensions. The extension usually identified the purpose/contents of the file. File size was specified as a multiple of 128 byte records, which corresponded to the disk sector size on 8 inch drives. • It was a single user operating system which included a simple interactive command interface, basic I/O device management, and a floppy-disk based file system.
Unlike CP/M early versions of SCP-DOS was designed for Intel’s new 16 bit microprocessor the 8086. While similar to CP/M it added features such as: • memory and timer management, • interrupt support, and a more sophisticated file system including a FAT table. • With more available memory, more commands could be built in to the command line logic, instead of loaded from executable files, making it faster and easier to use on floppy disk based systems. Eventually this program was acquired by Microsoft and renamed MS-DOS!!!
Many users also wished for a UNIX version for the PC. Although this wasn’t feasible with the hardware limitations of early PC’s, some existing OS’s tried to adopt some of the features which made UNIX popular. MS-DOS version 2 contained many UNIX like features including: • A command interface similar to the Unix shell • UNIX-like program interface, coexisting with the CP/M style system calls • Hierarchical file system • It wasn’t until later versions of Windows that support for multi-users and multi-tasking was introduced