Migration & Modernization

Deploying OpenVMS x86 on Amazon EC2

In this blog post, I will show you how to configure and run the x86 virtualized version of the OpenVMS operating system provided by VMS Software, Inc. in a cluster configuration on an Amazon Elastic Compute Cloud (Amazon EC2) bare metal instance. I will highlight integration points between OpenVMS guests running on the Amazon EC2 instance and a number of AWS services.

Introduction

OpenVMS is a midrange server operating system that was originally developed by Digital Equipment Corporation (DEC) in 1977. OpenVMS was known for breakthrough capabilities at the time including clustering, leading to unprecedented high availability. From the article, February 2018 Business & Technical Update from VMS Software Inc. the highest recorded uptime without a reboot was 17 years, by a European railway company. Modern operating systems including Windows Server and Linux have lineage back to OpenVMS. OpenVMS is still in use today in industry verticals that demand the utmost levels of uptime and security, such as financial institutions and manufacturing.

VSI OpenVMS V9.2 for x86-64 was the first production release for x86 virtualization that runs on VMware, KVM, and VirtualBox. With this release, it is now possible to instantiate OpenVMS guests under the KVM hypervisor on an Amazon EC2 bare metal instance.

Overview of solution

In this solution (Figure 1), I have provisioned an Amazon EC2 c5 bare metal instance running Red Hat Enterprise Linux (RHEL) 9 within a private subnet in an Amazon VPC. The KVM hypervisor is installed on this Amazon EC2 instance to host the OpenVMS guests. The KVM hypervisor also hosts AWS Storage GatewayAmazon S3 File Gateway and AWS Storage Gateway – Volume Gateway guests. The KVM local virtual network provides low-latency access to these AWS hybrid storage services from the OpenVMS guests. I will also highlight the AWS Transfer Family as an SFTP destination for the OpenVMS guests.

OpenVMS x86 cluster architecture on Amazon EC2

Figure 1 – OpenVMS x86 cluster architecture on Amazon EC2

Walkthrough

In this section, I will walk through deploying the Amazon EC2 instance, installation and configuration of the KVM hypervisor on the Amazon EC2 bare metal instance, installation and configuration of the OpenVMS guests, and installation and configuration of AWS Storage Gateway guests.

Prerequisites

To complete the steps described in this post, you will need the following:

  • An AWS account with at least one private subnet.
  • IAM permissions to launch AWS resources (Amazon EC2, AWS Storage Gateway, etc.).
  • Valid access to OpenVMS x86 virtualization packages from VMS Software, Inc.
  • Knowledge of OpenVMS operating system operations.
  • Foundational knowledge of RHEL 9.
  • Foundational knowledge of the KVM hypervisor.

Launch Amazon EC2 bare metal instance

In this step, I will launch a c5.metal Amazon EC2 instance with Red Hat Enterprise Linux 9 (Figure 2) into one of the private subnets within our VPC.

Amazon EC2 instance launch

Figure 2 – Amazon EC2 instance launch

Once the instance is launched, I can remotely access this host using a number of different methods including: EC2 Instance Connect, AWS Systems Manager Session Manager, SSH client, or EC2 serial console.

Install virtualization components

In this step, install the required virtualization packages on the Amazon EC2 instance using yum groups. Yum groups are RPM packages that have been logically grouped together. In this case, install the Virtualization Host group.

sudo yum group install “Virtualization Host” -y

You can verify successful installation using the virt-host-validate command.

# virt-host-validate
QEMU: Checking for hardware virtualization            : PASS
QEMU: Checking if device /dev/kvm exists              : PASS
QEMU: Checking if device /dev/kvm is accessible       : PASS
QEMU: Checking if device /dev/vhost-net exists        : PASS

Optionally, if you choose to run a RHEL 9 GUI, you can also install the virt-manager GUI (Figure 3).

sudo yum install virt-manager

Virtual Machine Manager

Figure 3 – Virtual Machine Manager

Install OpenVMS Guests

Follow these steps to install OpenVMS guests under KVM.

  1. Log into your account on the VMS Software, Inc. software portal at https://sp.vmssoftware.com.
  2. From the software portal, locate and download the latest X86VMS-OPENVMS-* zip file and extract the ISO. You will need this ISO for the OpenVMS installation. Copy the extracted ISO to the Amazon EC2 instance created earlier.
  3. From the software portal, locate and download the license PAK specific to your licensing arrangement.
  4. Follow the steps outlined in section 2.2, Creating a KVM/QEMU Virtual Machine from the VMS Software Installation Guide (VSI OpenVMS x86-64 Version 9.2-1) or the latest release. Pay particular attention to these items:
    1. Locate the X68VMS-OPENVMS-*.iso file for installation and set the bus type to SATA
    2. Unselect Automatically detect from the installation media/source box and type in Generic or unknown OS.
    3. Set a minimum of 8 GB memory and 2 CPUs.
    4. Set the disk size for your OpenVMS guest (suggestion is 16 GB). Be sure to set the SATA bus type.
    5. In the Overview section, select the Chipset: Q35 and the firmware as UEFI x86_64: /usr/share/*code*.
    6. Select Add Hardware and select Serial to add a serial device for the guest console.
    7. Make sure the network card is set to the default NAT virtual network and the device model is set as e1000
    8. From Boot Options, select Enable boot menu and enable SATA CDROM 1 as a boot device.
  5. Select Begin Installation.Once the OpenVMS guest boots, you will see the VMS Software BOOTMGR screen (Figure 4).
OpenVMS Boot Manager

Figure 4 – OpenVMS Boot Manager

  1. Type in B DKA100 at the prompt to begin the installation.
  2. At this point the guest console will show the message, GRAPHICAL OUTPUT HAS BEEN SUSPENDED – USE A TERMINAL UTILITY FOR ACCESS.

From a new terminal window, issue the command: virsh console <vm guest name> to open a serial console connection to the OpenVMS guest. (Figure 5).

virsh console to OpenVMS guest

Figure 5 – virsh console to OpenVMS guest

Integration with AWS Services

Now that there are OpenVMS guests running on our Amazon EC2 instance, there are several options for integration with AWS Services to be explored. I will highlight integration with these AWS Services.

  1. AWS Storage GatewayAmazon S3 File Gateway to share a NFS volume to OpenVMS as gateway to Amazon Simple Storage Service (Amazon S3).
  2. AWS Storage Gateway – Volume Gateway to present iSCSI block storage volume at the KVM hypervisor level to OpenVMS. The volume can then be mounted cluster-wide.
  3. AWS Transfer Family as a SFTP destination that can trigger file processing workloads and store the results in either Amazon S3 or Amazon Elastic File System (Amazon EFS).
  4. AWS Backup or AWS Elastic Disaster Recovery to provide disaster recovery and business continuity at the Amazon EC2 level.

Amazon S3 File Gateway

Follow the steps outlined in the AWS documentation, Amazon S3 File Gateway User Guide to create and activate an Amazon S3 File Gateway choosing the Linux KVM as the platform. This gateway is installed on the same KVM host as the OpenVMS guests. The OpenVMS guests communicate to the Storage Gateway across the KVM virtual network. An NFS file share is created on this gateway that points to an Amazon S3 bucket on the backend.

In this example, the Amazon S3 bucket is named sgw-openvms and the NFS file share is named the same. The file gateway is mounted to OpenVMS using the following command.

$ tcpip mount dnfs0: /path=”/sgw-openvms” /host=<Amazon S3 File Gateway host>
(where dnfs0: selects the next available device).

Once mounted, we can list the directory contents of the Amazon S3 bucket via the NFS share on OpenVMS and see the same objects within the Amazon S3 bucket (Figure 6). The file gateway cache can be automatically refreshed at the desired time interval. For more information see, Refreshing Amazon S3 bucket object cache.

Amazon S3 bucket via NFS share

Figure 6 – Amazon S3 bucket via NFS share

Amazon Volume Gateway

Follow the steps outlined in the AWS documentation, Volume Gateway User Guide to create and activate a Volume Gateway. choosing Linux KVM as the platform. The iSCSI target is mounted as a storage pool in KVM and shared to the OpenVMS guest. In this example, the device appears to the OpenVMS as DKA300: and is mounted across the OpenVMS cluster using the following command.

STA150>MOUNT/CLUSTER DKA300: SHARED /SYSTEM      
%MOUNT-I-MOUNTED, SHARED mounted on _STA150$DKA300:

All cluster nodes can now access the volume to store and retrieve data. From AWS, the volume can be part of an AWS Backup plan or scheduled EBS snapshots.

AWS Transfer Family

Follow the AWS Transfer Family User Guide to create a SFTP enabled server endpoint. In this example, an Amazon EFS file system is being used for the backend storage. Benefits of the AWS Transfer Family include the creation of managed file processing workflows to act upon once the OpenVMS guest pushes a file to the site.

From the OpenVMS guest, we can then connect to the SFTP endpoint.

STA150>sftp john.doe@ftp.example.com
john.doe@ftp.example.com's password:
Connected to ftp.example.com
sftp> dir
testfile.txt

This is the same file from an Amazon Linux host where the Amazon EFS file system is mounted.

sh-5.2$ mount -t efs -o tls fs-0123456789:/ /mnt/efs
sh-5.2$ ls /mnt/efs/home/john.doe/
testfile.txt

Business continuity and disaster recovery

At the Amazon EC2 level, we can protect the entire RHEL9 KVM host instance that is running the OpenVMS guests by including the Amazon EC2 instance in an AWS Backup plan or by using the AWS Elastic Disaster Recovery service. Both services offer in-region or cross-region configuration options. AWS Backup now also includes the ability to create logically air-gapped vaults for additional security features.

Cleaning up

If you have deployed any AWS resources by following the solution outlined in this blog, they will incur costs. To avoid any ongoing future charges, delete the resources created; specifically, the Amazon EC2 instance and the various Storage Gateway appliances that you no longer need.

Conclusion

In this post, I demonstrated how to configure and run the x86 virtualized version of the OpenVMS operating system on an Amazon EC2 bare metal instance. This enables customers to run OpenVMS in the AWS Cloud, move away from legacy hardware on the datacenter floor, and pave the way for future modernization. I also demonstrated a number of integration points between OpenVMS and AWS services. The possibilities are practically endless! For more information about OpenVMS licenses, training, professional services, and other questions reach out to VMS Software at sales@vmssoftware.com

Ready to get started? Read more blog posts related to migration and modernization on the Migration & Modernization Blog and other mainframe modernization posts on the AWS Cloud Operations Blog.

About the Author