hillgang - cloning in a mainframe environment · pdf filecloning in a mainframe environment...

36
Cloning In A Mainframe Environment z/OS z/VM z/Linux Jim Moling Financial Management Service Email: [email protected]

Upload: lyanh

Post on 06-Feb-2018

227 views

Category:

Documents


0 download

TRANSCRIPT

Cloning In A Mainframe Environment

z/OS

z/VM

z/Linux

Jim MolingFinancial Management Service

Email: [email protected]

12/18/2008 Jim Moling, US Treasury, FMS 2

DisclaimersThe opinions & ideas expressed herein are those of the author alone and do not necessarily reflect those of Financial Management Service, furthermore, Financial Management Service is hereby absolved of any and all responsibility or liability for the information contained herein.

Copyrights & Trademarks:� Any and all copyrights & trademarks are hereby acknowledged to be owned by their

respective parties� All other brands, logos and products are trademarks or registered trademarks of their

respective companies� All rights reserved

Disclaimer of Endorsement:� Reference herein to any specific commercial products, process, or service by trade name,

trademark, manufacturer, or otherwise, does not necessarily constitute or imply its endorsement, recommendation, or favoring by the United States Government. The views and opinions of authors expressed herein do not necessarily state or reflect those of the United States Government, and shall not be used for advertising or product endorsement purposes.

Disclaimer of Liability:� With respect to this presentation, neither the United States Government nor any of their

employees, makes any warranty, express or implied, including the warranties of merchantability and fitness for a particular purpose, or assumes any legal liability or responsibility for the accuracy, completeness, or usefulness of any information, apparatus, product, or process disclosed, or represents that its use would not infringe privately owned rights.

12/18/2008 Jim Moling, US Treasury, FMS 3

Overview

Virtualization: Benefits Of System z & z/VM

z/Linux: Virtual Servers On System z

Principles: Why, What & How Of Cloning

Example: How We Are Cloning z/VM

Summary: Where Do We Go From Here…

12/18/2008 Jim Moling, US Treasury, FMS 4

Benefits Of System z & z/VM

Key System z Features:� Virtualization Technology

� PR/SM – Logical Partitions (LPARs)

� Specialty Engines: IFL, zAAP, zIIP

� High Speed Connectivity� FICON, FCP, OSA

� Advanced Security Features� Crypto coprocessor & SSL accelerator

� Resiliency – “z”ero Down Time�Designed for %99.999 availability

12/18/2008 Jim Moling, US Treasury, FMS 5

Benefits Of System z & z/VM

� Virtual Servers run in a Logical Partition (LPAR) of a mainframe complex

� z/VM is an IBM operating system that provides a virtualized environment within an LPAR

� 100’s of Virtual Servers can run in a mainframe LPAR

12/18/2008 Jim Moling, US Treasury, FMS 6

z/VM Virtualizes Resources

� Supports Hundreds of Virtual Machines

� Virtualizes CPU

� Virtualizes Memory

� Virtualizes DASD (Disk)

� Provides Virtual Switches

� Provides Virtual LANs

Benefits Of System z & z/VM

12/18/2008 Jim Moling, US Treasury, FMS 7

Benefits Of System z & z/VM

A 3-tier Defense-In-Depth approach can be implemented in a z/VM virtual environment

Security Considerations

12/18/2008 Jim Moling, US Treasury, FMS 8

Benefits Of System z & z/VM

Servers can “plug” into existing infrastructure for mainframe disaster recovery

Server DASD can now be added to the XRC-based mirrored DASD ranges (Availability – Q1 2009)

Disaster Recovery Benefits

12/18/2008 Jim Moling, US Treasury, FMS 9

Virtual Servers On System z

Linux is an Open Source operating system

IBM developed mainframe drivers for Linux

SUSE Linux Enterprise Server (SLES) was created for IBM mainframes

All (our) virtual servers run the SLES operating system

Novell provides marketing & support

Virtual Servers Are Linux Based

12/18/2008 Jim Moling, US Treasury, FMS 10

Virtual Servers On System z

o Since the Linux operating system is Open Source, cost is minimal, i.e. only paying for support

o Since resources are shared, they can be maximized, i.e. CPU, memory, disk storage are not wasted – they are used to their fullest extent

o Significant software license savings when based on the number of IFL’s, i.e. since one IFL can run 25-50 servers, only 1 software license is required, thus saving up to 24-49 licenses per IFL

o The more virtual servers implemented, the greater the savings that can be realized

Significant Cost Savings

12/18/2008 Jim Moling, US Treasury, FMS 11

Virtual Servers On System z

o Each virtual server implementation saves the cost of a physical server + S/W Licenses (beyond break points)

IBM IFL 80,000$ 5,000$ Server Box

4GB Memory 40,000$ -$

z/VM 22,440$ -$

SUSE Linux 30,000$ 2,000$

1 Server: 172,440$ 7,000$

25 Servers: 172,440$ < Break Point > 175,000$

50 Servers: 172,440$ 350,000$

100 Servers: 172,440$ 700,000$

Virtual Servers Real Servers

Hardware Cost Comparison

Virtual Servers Real Servers

IBM WAS 20,000$ 20,000$

IBM UDB/DB2 32,294$ 32,294$

1 Server: 52,294$ < Break Point > 52,294$

5 Servers: 52,294$ 261,470$

10 Servers: 52,294$ 522,940$

25 Servers: 52,294$ 1,307,350$

50 Servers: 52,294$ 2,614,700$

Server Software Cost Comparison

Significant Cost Savings

12/18/2008 Jim Moling, US Treasury, FMS 12

Virtual Servers On System z

The Integrated Facility for Linux (IFL) is a special CPU engine in the mainframe complex

An IFL is only used for Linux (And z/VM) – Not z/OS!

1 IFL ~ 25 to 50 Servers (depends on activity!)

Virtual Servers Use IFL’s

12/18/2008 Jim Moling, US Treasury, FMS 13

Virtual Servers On System z

Internal connections are called Hipersockets

Very Fast – Memory-based transfer speeds

Very Secure – No exposure to the network

Very Reliable – Immune to network outages

Z/Linux To z/OS Connectivity

12/18/2008 Jim Moling, US Treasury, FMS 14

Virtual Servers On System z

TSM Servers

CCL Servers

App & DB Servers

File & Print Servers

Firewall Servers

LDAP Servers

Logging Servers

Current Virtual Servers

12/18/2008 Jim Moling, US Treasury, FMS 15

Virtual Servers On System z

Application Servers (50)

Database Servers (35)

Web Servers (59)

Infrastructure Servers (93)

More servers have been added since – getting closer to 300 virtual server candidates!

Potential Virtual Server Candidates

12/18/2008 Jim Moling, US Treasury, FMS 16

The Why, What & How Of Cloning

Why Cloning?

� Standardized configurations

� Facilitates maintenance testing/rollout

� Cost savings

� Time savings

12/18/2008 Jim Moling, US Treasury, FMS 17

The Why, What & How Of Cloning

What Are We Cloning?

� Operating Systems That Run On System z

� z/VM: A Hypervisor for operating systems

� z/OS: Large enterprise class systems

� z/Linux: Linux based server systems

z/Linux z/VM z/OS

12/18/2008 Jim Moling, US Treasury, FMS 18

The Why, What & How Of Cloning

Cloning z/OS Was First

� z/OS was the first operating system that we cloned

� We now have 18 z/OS systems across 2 data centers (and growing)

� Takes the longest to clone: ~ 2.5-3 Hours

� Cloned by running ~50 batch jobs in z/OS!

12/18/2008 Jim Moling, US Treasury, FMS 19

The Why, What & How Of Cloning

Cloning Virtual Linux Servers Was Next

� We have 20+ Virtual Servers (and growing)

� Virtual Servers are cloned in minutes (5-20)

� Cloning is via a “Controller” Linux Server

� Based on IBM Virtualization Cookbook

12/18/2008 Jim Moling, US Treasury, FMS 20

The Why, What & How Of Cloning

Finally, We’re Cloning z/VM Systems

� We now have 8 z/VM systems across 2 data centers (and growing)

� Takes about 20-30 minutes to clone z/VM

� Only takes 2-3 minutes when FlashCopy is available

� Cloning is via a “Cloning” Virtual Machine

� If all goes well, you’ll see a demo of this …

12/18/2008 Jim Moling, US Treasury, FMS 21

The Why, What & How Of Cloning

How Is Cloning Accomplished?

� Establish standards that support duplication

� Establish a “Base” system as the prototype

� Develop an automated cloning procedure

� Clone a system from a like system (my rule)

12/18/2008 Jim Moling, US Treasury, FMS 22

How We Are Cloning z/VM

z/VM Cloning Considerations

� Cloning process was developed using z/VM Version 5.2.0

� Running in a shared DASD environment

� Each z/VM system must have unique volumes

� Based On Shipped Configuration From IBM

�Using a single, 3390-9 volume for SYSRES

�Not Using Dirmaint, SFS, External Security, …

12/18/2008 Jim Moling, US Treasury, FMS 23

How We Are Cloning z/VM

Cloning process is based on shipped configuration + User volume

12/18/2008 Jim Moling, US Treasury, FMS 24

How We Are Cloning z/VM

Two Files Must Be Modified In A Cloned System

� SYSTEM CONFIG (Located on Parm Disk, i.e. CF1)

� USER DIRECT (Shipped on MAINT’s 2CC minidisk)

12/18/2008 Jim Moling, US Treasury, FMS 25

How We Are Cloning z/VM

Conventions/Standards

� Naming standard for System ID (SYSID)

� Naming standard for system volumes

� Created a VM Directory cloning model

� Created a System Config cloning model

� Added a User volume to the configuration

12/18/2008 Jim Moling, US Treasury, FMS 26

How We Are Cloning z/VM

Naming Standard – SYSID� Using a 4-char SYSID to drive the cloning process

� All system files can co-exist since names are unique (based on SYSID), i.e. System Configs, VM Directories, TCP/IP files, etc.

� Volsers are also based on SYSID to make them unique

� SYSID format: VMnx, where:� VM = Common prefix so VM systems & volumes are unique (from z/OS & z/Linux in our case)

� n = a number that represents the data center

� x = a letter to designate the VM system

SYSID=VM1R

12/18/2008 Jim Moling, US Treasury, FMS 27

How We Are Cloning z/VMNaming Standard – System Volsers� Volser format: VMnx + V# = VMnxV#

� First 4 characters are the SYSID, i.e. VMnx (like VM1R)

� 5th character indicates volume type: V = R, P, S, U

� 6th character is a number to keep same volume types unique: # = 1-9 (except SYSRES is always S, i.e. RS)

� Note that current cloning process does not include TDISK volumes – we just haven’t needed them� TDISK volume type would be T, i.e. VM1RT1

� Cloning can be modified to include TDISK’s (if you modify execs)

V#=RS V#=S1 V#=P1 V#=U1

SYSID=VM1R

12/18/2008 Jim Moling, US Treasury, FMS 28

How We Are Cloning z/VMCloning Models Give Consistent Results� Cloning will only change volsers for a new system

� Cloning models should have basic definitions – you decide what they should be� System Config Model: fn=<Source Sysid> ft=$CONFIG$

� User Directory Model: fn=<Source Sysid> ft=$DIRECT$

� You can always modify the new files after cloning� New System Config: fn=<New Sysid> ft=CONFIG

� New User Directory: fn=<New Sysid> ft=DIRECT

Note: ‘fn’ means ‘file name’ & ‘ft’ means ‘file type’

12/18/2008 Jim Moling, US Treasury, FMS 29

How We Are Cloning z/VM

Why Add A User Volume?

� Simplifies moving to a new version of z/VM

� Simplifies maintenance via full SYSRES replacement

� Easy to clone – just 1 more DASD volume to copy

� Conventions:

� Always allocate new minidisks on the User volume

� This means no more allocations on the SYSRES volume!

� Using low-end cylinders for VM users (we only have a few)

� Using high-end cylinders for VM tools & utilities

12/18/2008 Jim Moling, US Treasury, FMS 30

How We Are Cloning z/VM

Preparation For Cloning

� Setup a cloning virtual machine called: VMCLONER

� Make sure it has the same authorities as MAINT

� OPTION MAINTCCW LNKS LNKE LNKNOPAS DEVMAINT

� TCP/IP access: define OSA triplet or VSwitch-based NIC

� Can attach a QDIO OSA triplet if available, or

� We define a virtual NIC that points to a VSwitch

� Wrote a few Rexx programs to perform the cloning & IPL processes:

� CLONEVM – Performs the cloning process

� IPLVM – Performs an IPL of the cloned system

� TESTIPL – IPLVM front-end with IPL instructions

12/18/2008 Jim Moling, US Treasury, FMS 31

How We Are Cloning z/VM

Cloning Process …

� Logon to the VMCLONER virtual machine

� Run the CLONEVM exec to create a parm file where you specify:

� The SYSID of the new system, i.e. VM1R

� The DASD addresses for the new system

� The Source SYSID that you’re cloning from

� The Source Volser Prefix you’re cloning from

� The Source Model files for the System Config & User Directory

� Save the parm file with these changes

12/18/2008 Jim Moling, US Treasury, FMS 32

How We Are Cloning z/VM

Editing the parm file:CLONEVM $MODEL$ A1 F 80 Trunc=80 Size=183 Line=0 Col=1 Alt=0

====>

00000 * * * Top of File * * *

00001 * ======================================================================

00002 * ============> Parameter File For Cloning A New VM System <============

00004 * ======================================================================

00005

00006 * < Specify Source & Target Information For Cloning A New System >

00007

00008 * ----------------------------------------------------------------------

00009 * New (Target) System Information

00010 * ----------------------------------------------------------------------

00011 * Specify The New (Target) System & DASD Volumes That Will Be Cloned To:

00012

00013 NewID = VM1R

00014

00015 NewResA = 1234

.

.

.

12/18/2008 Jim Moling, US Treasury, FMS 33

How We Are Cloning z/VM

Cloning Process …� Execute the CLONEVM exec

� Specify the new SYSID as a parm to CLONEVM� For example: CLONEVM VM1R

� The cloning process consists of 8 steps

� There are many prompts during it’s execution, so that it can be easily aborted if something doesn’t look right

� Hopefully you’ll see how it executes during the demo …

12/18/2008 Jim Moling, US Treasury, FMS 34

How We Are Cloning z/VM

Cloning Process …

� 9 steps are executed by CLONEVM:

1. GetParms – Reads Cloning Parameters From A File

2. DefVols – Defines volsers & verifies addresses

3. ClipVols – Clips the volsers of all target DASD

4. LinkVols – Links to all source & target volumes

5. CloneDir – Clones the VM Directory source file

6. CloneCfg – Clones the System Config file

7. CloneVol – Clones the new system volumes

8. WriteDir – Writes VM Directory to new SYSRES

9. PageVols – Formats the new PAGE volume(s)

12/18/2008 Jim Moling, US Treasury, FMS 35

How We Are Cloning z/VM

Cloning Process …

� Once CLONEVM has completed, then run TESTIPL

� The TESTIPL Rexx exec provides instructions on performing the first IPL of a newly cloned system, then calls the IPLVM Rexx exec

� Specify the new SYSID as a parm to TESTIPL

� For example: TESTIPL VM1R

� The IPLVM Rexx exec allows you to easily run another VM system “2nd level”

� The IPLVM exec defines terminals so you can dial into VMCLONER locally to check out the new system

� TCP/IP access is also possible, but you’ll have to set it up to work in your environment! (see IPLVM exec comments)

12/18/2008 Jim Moling, US Treasury, FMS 36

Where Do We Go From Here…Lots of room for improvement in this cloning process, but it’s a start!

Some of the improvements that are in the works:� Working on Xedit panel displays for entering parameters

� Working on a Read-Only SYSRES configuration

� Working on further developments based on a read-only SYSRES that will assist in applying maintenance to z/VM

If you’re interested in a copy of the current execs

(and this presentation) shoot me an email at:[email protected]

If someone wants to put these on their website …

=> You can now find it at:http://sinenomine.net/publications/conference/hillgang