By David Kreuter published: Thursday, July 22 2004
In this article the concepts of virtualization and its implementation in the mainframe arena are introduced, with a focus on IBM’s z/VM (Virtual Machine) operating system.
By using VM, multiple systems are virtualized; each user of VM believes that they have a full independent mainframe environment.
Virtual machines run operating systems. The operating systems run in virtual machines must be compliant with IBM mainframe architecture. The requirement for the operating system that runs in a virtual machine is adherence to IBM mainframe architecture. The operating systems that run in a virtual machine are VM itself, z/OS, MVS, VSE, utility operating systems, and the newest virtual machine operating system: Linux.
The Virtual Machine operating system provides a complete virtualization of the IBM mainframe architecture. VM has been doing this virtualization for over 30 years. It does this through a combination of these major precepts of virtualization: resource sharing, resource simulation, and controlling the provisioning and management of multiple virtualized systems – referred to as virtual machines. Real resources are provisioned to virtual machine by the control program (CP) of VM. Real resources can be shared by time through the CPU, or by physical allocation through disk space.
Resources can be virtual or real and include CPU, memory, I/O devices including terminals, tape drives, disks, printers and network devices (network interface cards and switches).
The CPU is provisioned to a virtual machine by using the real and virtual techniques. Real usage occurs through time sharing. When a virtual machine needs CPU instructions, it is allowed to execute instructions on a CPU for certain amount of time: the time slice. Certain CPU instructions and facilities cannot be provided directly by the CPU; some because of control and integrity issues, other because they are used to communicate information to CP. These instructions are provided by the technique of simulation: one instruction to the virtual machine will cause hundreds or thousands of instructions to be executed by CP that will mimic the instruction to the virtual machine.
Memory is provided through virtualization in the hardware and the CP software. When a virtual machine references an address, the hardware automatically does dynamic address translation. The real storage location is shielded from the virtual machine. The virtual machine is unaware of the real storage location. By exploiting hardware dynamic address translation, the storage references of different virtual systems are isolated from one another. No integrity issues are possible. Each virtual machine can refer to the same location in a program, say, x’1000’, and that address will be in two different and isolated real storage locations.
What happens in the event that the total of virtual machine memory requirements exceeds that of real memory? This is virtualized through a mechanism called paging. When an address that is needed by a virtual machine is not in real memory, the control program will be notified through a special signal, known as an interrupt. This interrupt will be decoded by CP. CP will then initiate an I/O operation to fetch the page from an auxiliary disk storage device known as DASD. Some amount of paging is typical of the VM operating system. This close relationship of the hardware and software is key to the success of the virtualization strategy of IBM mainframe systems.
I/O is provided through actualization and virtualization. Some devices are completely virtualized; that is, the device doesn’t actually physically exist. Rather CP provides the simulation of the I/O instructions for the device, and stores the data in memory or DASD buffers. This is referred to as spooling. Spool devices for a virtual machine are a card reader, card punch, and impact printer. Sharing of the spool files is quick and easy.
Other I/O devices are actualized by sharing. Consider the situation where one physical disk contains roughly 3 gigabytes of space. A virtual machine might have a much smaller space requirement, say 50 megabytes. Rather than devoting all of a 3 gigabyte disk to a virtual machine and wasting most of its space, a disk is carved up into smaller units known as minidisks. When a virtual machine reads or writes a file on a minidisk, CP gets involved to translate the I/O instructions to the correct real locations on the disk.
The newest area of virtualization is VM virtual network devices and guest LANs. A virtual machine can have a simulated network interface card provided completely through instruction simulation, a totally virtual device. A virtual NIC card comes complete with a virtual MAC address, and can be configured with an IP address. No cables, wires, or physical cards, it’s all done by software. Virtual machines with NIC cards can join a guest LAN. A guest is virtualized LAN environment, free of cabling and hardware devices.
This is especially useful to the Linux operating system. Multiple virtual machines can run Linux under a single instance of VM. These virtual Linux images can be networked together on guest LANs with virtual NIC cards. You can have many guest LANs in one instance of VM, supporting isolated or joined networks. The only limit is your imagination in network design.
IBM is leveraging VM-style virtualization technology across its product line this year. This technology, known as Virtualization Engine technology, lets customers partition a CPU into different virtual CPUs, providing up to ten virtual CPUs on one real CPU. This will let up to ten servers running different operating systems co-exist harmoniously on one server
The Virtualization Engine contains software tools for provisioning and managing these virtual servers from a single focal point. Again this will utilize concepts that have matured on z/VM for over thirty-five years. IBM expects the cost savings for customers resulting from higher hardware utilization rates and better systems management tools to be significant.
This article shows how the IBM z/VM operating system provides virtualized computing facilities to multiple incantations of different operating systems. One of the modern uses for this virtualized world is running multiple instances of Linux under a single instance of z/VM. z/VM is an old and yet vital way of providing cost effective virtual systems.
David Kreuter, President of VM Resources Ltd., has been writing assembler code for over 20 years. He has written countless assembler routines including development on small reporting tools, modifications to ancient versions of CMS, bridges between high level languages, Callable Services Libraries in CMS, and developing zVM exits and code modifications for customers with very specific needs for resource protection and data encryption. He has given numerous presentations on assembler coding and operating system debugging, and has written courseware and taught operating system debugging at IBM. You can reach David at dkreuter@vm-resources.com.