Introduction to the Preconfigured Qemu Grid tools

Understanding the current forms in which the qemu preinstalled images are distributed requires understanding how the 'pieces' of Plan 9 fit together. To summarize, a standard modern Plan 9 system is built from a Venti server providing archival data storage, a Fossil server providing a termporary write buffer to the Venti and serving the data via 9p as a filesystem, a CPU server to run applications, and a terminal to provide a graphical display and control of the i/o devices. These pieces are independent, and can be setup as a single, all-in-one system, or each can be provided by a separate machine. A medium-to-large Plan 9 installation may have multiple machines performing each of these roles, with the user terminal making use of some resources from each.

The qemu gridtools allow the user to easily and quickly create a local grid of these plan 9 services, either on a single machine 'distributed' amongst VMs, or using multiple physical machines in various roles. We will step through the simple default setups created by the gridlord utility in the gridtoolsplus version. The user unpacks the distribution, cd's into the gridtoolsplus folder, sets up port redirections as superuser using tools/iptablescript, and then starts gridlord. What happens next:

Venti Data Server ->Fossil File Server ->CPU Execution Server ->Display + I/O Terminal
Plan 9 portQEMU VMQEMU VMDrawterm
Host OS via vacHost OS via drawterm

So this represents an example of building a 'distributed system' on a single box. The same architecture could be used with each component running on a separate machine. One machine run the venti and be dialed by the fossil on a different machine at boot, which in turn will be dialed at bootup by the cpu server on a separate machine, which in term can be connected to remotely via drawterm from any location. Furthermore, additional nodes can be added in, such as more file servers and cpu servers. Any number of cpu servers can in theory boot from a single file server, any number of file servers can connect to a given venti, and the user may make use of all of the resources in the configuration they wish from their terminal.

Creating customized systems between machines and with additional nodes of requires some reconfiguration - for instance, a fossil file server needs to know the IP address with which to dial the venti server. The gridtools include in /usr/bootes/bin/rc a confighelper tool to assist with customizing grid nodes.

The above description was based on the prescripted actions of the gridlord tool provided for linux and made use a linux-hosted plan9port Venti. The same distributed architecture can be created on Windows machines, or Linux/other UNIX related OSes not using Plan 9 port. It should be noted that the 'full' architecture shown above is not required for the use of Plan 9 or the 9gridchan qemu tools. It is entirely possible to use the standalone version of the image as a single all in one machine with local fileserver - and if you wish, you can even dispense with drawterm and use the virtual machine via its own graphic interface.

To implement the full distributed architecture without plan9port venti, it is necessary to shift the role of Venti server to a qemu VM. There is no difference in the ultimate environment created for the user, but currently this configuration needs to be created by the user by launching the VMs in turn with the appropriate port redirections. The preconfigured machines assume they are all being run on the same physical machine and communicate with 127.0.0.1 (not configured as loopback!). If you wish to separate them to different physical machines, the capacity to specifiy venti server address and name at boot may be convenient in helping reconfiguration.