Introduction to VM - The User Directory ======================================= OK, so you've now got a little understanding of VM, and some sense of the way it works. As with all computer stuff, there's a lot more to it than that, and any questions you may have probably all have the answer 'it depends'. To recap: We have VM installed on our swish new mainframe, and have successfully IPLed CP. 'IPL' is IBM-speak for 'boot' ('Initial Program Load'). You *do* remember what CP is, don't you? So what now? Virtual machines are defined to CP via the 'user directory'. Now, I found this a bit confusing at first. The virtual machines are known as 'users', and there is no concept of userids or logins in the same way as on eg. Unix or Windows systems. The reason for this is that originally, VM was intended to enable time-sharing and multi-user operation by giving each end-user their own single-user virtual machine. This of course, is the opposite way to how most current systems work ie. one operating system image accessed concurrently by many users. Strictly speaking, it *is* possible to log on to and remain in CP as a 'user' in the more conventional sense, but as CP only really provides facilities for managing hardware and virtual machines, you're not going to get much actual work done there! Let's take a look at an example user directory entry: USER LEEB SECRET1 16M 64M ABCDEFG MACHINE ESA IPL CMS CONSOLE 009 3215 SPOOL 00C 2540 READER * SPOOL 00D 2540 PUNCH A SPOOL 00E 1403 A LINK MAINT 190 190 RR LINK MAINT 19E 19E RR LINK MAINT 19D 19D RR MDISK 191 3390 0001 0020 USER01 MR ALL MDISK 400 3390 0021 0500 USER01 R ALL MDISK 123 3390 000 END 240RES MW ALL OK. Doesn't make a great deal of sense at first glance. Let's go through it line-by-line. USER LEEB SECRET1 16M 64M ABCDEFG This defines a user (virtual machine) 'leeb', with password 'secret1'. The leeb virtual machine starts with 16MB of RAM ('real storage' in mainframe-speak), and is permitted to extend that up to 64MB if required. The last field, seemingly a partial recitation of the alphabet, defines the privilege levels this user holds. Privilege levels in CP detemine what you can request of CP in terms of virtual machine operations, and CP management functions. So, for example, 'C' (system programmer) can change system-wide parameters in CP. 'G' (general user) is restricted to CP commands associated with their virtual machine. Naturally, I gave myself full access :-) There are other levels available, and a big slice of the alphabet is given over to user-definable levels. MACHINE ESA This directive describes the architecture of the virtual machine. The capabilities of this directive do depend on the version of VM and the underlying real hardware, but it may be possible to eg. run z/VM (64-bit) at the top level with a VM/ESA (31-bit) guest second level, and a VM/SP (24-bit) guest under VM/ESA (with say, an ancient version of MVS running as a VM/SP guest). The question then arises: "What kind of madman would do such a thing?". I don't know the answer to that question, but you can see how it might be useful (albeit not officially supported) to keep some of those legacy systems running that you just don't seem to be able to shake off. You may have seen VMWare et al put to similar use on x86. IPL CMS This line will automatically boot the named operating system when you start up (ie. log in as) your virtual machine. CMS is definitely going to be in another article. For now, just know that CMS is a single-user OS commonly used with (and provided as part of) VM. I know you haven't already forgotten what 'IPL' means. CONSOLE 009 3215 SPOOL 00C 2540 READER * SPOOL 00D 2540 PUNCH A SPOOL 00E 1403 A These lines define some virtual devices for the virtual machine. CONSOLE is fairly self-explanatory, the first SPOOL defines a virtual punch-card reader, the second a virtual card punch, and the third a virtual printer. I think this stuff will be in a separate article. For the time being, it's enough to know that VM can provide virtual devices to your virtual machine, which have no real device equivalent. The three-digit hex number after the SPOOL and CONSOLE directives is the address of the device *as it will appear inside your virtual machine* I'll skip over LINK just now, and go on to: MDISK 191 3390 0001 0020 USER01 MR ALL MDISK 400 3390 0021 0500 USER01 R ALL MDISK 123 3390 000 END 240RES MW ALL These lines define virtual hard disks to your virtual machine. VM uses 'minidisk' to denote virtual disk storage devices, hence MDISK. I think I'll break out disk storage into another article too... Similar to SPOOL and CONSOLE, the hex number after MDISK defines the address of the disk inside your virtual machine. Now lets look at LINK: LINK MAINT 190 190 RR LINK MAINT 19E 19E RR LINK MAINT 19D 19D RR The LINK directive allows your virtual machine to access other virtual disks in the VM system. This is very useful for sharing software and data between virtual machines under the control of CP. For instance, maybe a development suite (compiler, debugger etc.) is installed somewhere. Accessing the minidisk(s) from your virtual machine means you can now make use of that software, and so get cracking on your Zork port for VM. Or maybe something less interesting. Anyway. These LINK directives specify that we're going to link to three minidisks (owned by user MAINT) at addresses 190, 19E, and 19D (in the MAINT virtual machine), and we're going to access them at the same addresses in our virtual machine. 'RR' is read-only, because to be honest, MAINT probably doesn't want us screwing up all his hard work. So, you log in ('logon' in the mainframe world) as your virtual machine user 'leeb', enter the correct password, then CP goes away and: - allocates you a bit of RAM - sets up some virtual devices for you - locates your virtual disks in the system (probably on some SAN or disk array across the computer room somewhere) - Tries to access the MAINT disks and add them to the devices available to your virtual machine - Attempts to start your OS (CMS) in the virtual environment it has just prepared for you. All being well, you see: FILES: 0001 RDR, 0001 PRT, NO PUN LOGON AT 15:30:49 JST SATURDAY 01/12/19 VM/ESA V2.4.0 1999-09-24 09:18 Ready; T=0.06/0.08 15:30:51 at your terminal and away you go!