CSM: Convert HFS to ZFS file systems.
search cancel

CSM: Convert HFS to ZFS file systems.

book

Article ID: 217170

calendar_today

Updated On:

Products

CHORUS SOFTWARE MANAGER

Issue/Introduction

What is the process to convert CSM file systems from HFS to ZFS?

Environment

Release : 6.0

Component : Chorus Software Manager

Resolution

  1. Shutdown the MSMTC and MSMDBSRV tasks. Make sure that parameter to Unmount File Systems at Shutdown is enabled (Settings Tab è System Settingsè Mountpoint Management) prior to beginning shutdown first.  All of the MSM/CSM Applciation file systems should be unmounted before beginning the conversion process.
  2. Using the CSM JCL member, MSMDBSQL, in the MSM/CSM runtime JCL PDS, execute the SQL to print the current content of the MSM/CSM Mountpoint and UserConfig tables.
    1. Review JOBCARD to meet your site requirements
    2. Review JOBLIB DD statements to verify against your site specific datasets
    3. Replace the SYSIN DD Input statements, with the following:

//SYSIN    DD  *                                     

  Select * from mountpoint;

  Select * from userconfig;

/*  

  1. Review STDOUT for Mountpoint table, verifying that all of the MP_DATASET fields have same HFS HLQ. NOTE: there could be product specific datasets in this table.  This document does not cover conversion of these datasets, just the CSM product datasets.  If the HFS HLQ is not consistent across the table entries, you will need to contact CA Support for assistance before proceeding.
  1. Shutdown the MSMMUF STC.
  2. Use the IBM HFS to ZFS file system migration tool, BPXWH2Z, to convert the MSM/CSM Application File systems from HFS to ZFS format. This utility is documented in the IBM UNIX System Services Planning (GA22-7800-19). 
    1. This utility requires specification of arguments which determine the actions to be performed. The arguments specify the datasets to be migrated, name change to be made, any allocation changes to be used when allocating the new ZFS datasets.  These are documented in the utility help panels.
    2. You can execute the utility from ISPF Panels or through the ISPF Batch facility. We recommend running the utility through the batch facility due to the number of datasets that may be involved in the conversion effort for MSM/CSM.  A Sample JCL for executing the utility via ISPF Batch Utility is provided in Appendix A of this document.
    3. This is an example of the arguments that would be passed for the MSM/CSM conversion:

ISPSTART CMD(BPXWH2Z -VC /fromstring/tostring/ <dataset mask of HFS datasets to convert>)

So, to convert all of the datasets named MF20.MSM.HFS to MF20.MSM.ZFS, we would use the following:

ISPSTART CMD(BPXWH2Z -VC /HFS/ZFS/ MF20.MSM.HFS)

  1. You must run this with superuser authority or must have authority to switch to superuser. Additionally, the user must be permitted to BPX.FILEATTR.* profiles in the FACILITY class and must also have authority to rename the HFS data sets you are migrating and authority to create, rename, and delete the new zFS data sets.                 
  1. Start the MSMMUF STC Task
  2. Use the JCL created in Step 2 above to execute additional SQL to update the MSM/CSM Mountpoint and Userconfig tables with new, ZFS, parameters.
    1. Replace the SYSIN DD Input statements, with the following:  (You will need to review each parameter carefully to determine if it is needed for your specific HFS to ZFS environment. Contact CA Support if you have questions or need assistance)

//SYSIN    DD  *              

   UPDATE mountpoint                                   

   SET mountpoint.MP_OPTIONS = ' system;ZFS'                    

    WHERE mountpoint.MP_TYPE =’APLROOT’;     

 

  UPDATE mountpoint                                   

  SET mountpoint.MP_OPTIONS = 'ZFS'                    

   WHERE SUBSTR(mountpoint.MP_DATASET,1,??) =’<HFS HLQ>’ AND

      mountpoint.MP_OPTIONS =’HFS’;          

 

  UPDATE mountpoint                                   

  SET mountpoint.MP_DATASET = '<new ZFS HLQ>' ||

      SUBSTR(mountpoint.MP_DATASET,##)                    

  WHERE SUBSTR(mountpoint.MP_DATASET,1,??) =’<HFS HLQ>’;       

  UPDATE USERCONFIG                                   

  SET VALUE='ZFS'        

      WHERE KEY= ‘mpmFilesystemType’; 

 

  UPDATE USERCONFIG                                   

  SET VALUE='<new ZFS HLQ>'        

      WHERE KEY= ’mpmHlq’; 

 

NOTE:  The remainder of these parameters will only be required if the allocation attributes will change for the ZFS file system datasets.

  UPDATE USERCONFIG                                   

  SET VALUE='<new ZFS allocation attribute>'        

      WHERE KEY= ’mpmAllocation’; 

  UPDATE USERCONFIG                                   

  SET VALUE='<new ZFS volser>'        

    WHERE KEY= ’mpmVolser’; 

  UPDATE USERCONFIG                                   

  SET VALUE='<new ZFS UNIT>'        

      WHERE KEY= ’mpmUnit’; 

  UPDATE USERCONFIG                                   

  SET VALUE='<new ZFS StorClass>'        

      WHERE KEY= ’mpmStorclas’; 

  UPDATE USERCONFIG                                   

  SET VALUE='<new ZFS MgmtClas>'        

      WHERE KEY= ‘mpmMgmtclas’; 

  UPDATE USERCONFIG                                   

  SET VALUE='<new ZFS Dataclas>'        

      WHERE KEY=  ‘mpmDataclas’; 

/*  

NOTES on Control Cards

  1. Change parameter <> to value for your site.
  2. Change ?? to length of the <HFS HLQ> (example, if HFS HLQ is MF20.MSM.HFS, ?? is 12)
  3. Change ## to ?? plus 1 (?? isvalue specified in Note 2 above). This represents the first character in each HFS dataset name that will be retained in the new ZFS Dataset names.  (Example, if HFS dataset names are MF20.MSM.HFS.APLROOT, ## is 13.  This will mean the period after HFS node will begin string appended to new ZFS HLQ)

                         

  1. Replace the SYSIN DD Input statements, with the following:

//SYSIN    DD  *                                      

  Select * from mountpoint;

  Select * from userconfig;

/* 

Verify Content of Mountpoint Table from STDOUT sysout, ensuring MP_DATASET and MP_OPTIONS now reflect ZFS

Verify Content of UserConfig Table from STDOUT sysout, ensuring the HLQ and allocation parameters are correct for ZFS datasets, including the following:

     

mpmFilesystemType

mpmHlq

mpmAllocation 

mpmVolser 

mpmUnit 

mpmStorclas

mpmMgmtclas

mpmDataclas

  1. Start the MSMDBSRV and MSMTC STCs
  2. Log in to MSM/CSM to verify access to Product Catalog, SME/E Environment, and Output Tasks.
  3. Update the following MSM/CSM parameters and parms to ensure upgrades going forward use correct parameters:
    1. Edit /u/users/msmserv/<version>/msm/CEGPHFS/MSMSetupOptionsFile.properties and change the following parameters:
      1. MVSHFSDsnPrefix - If dataset names changed with conversion
      2. USSFileSystemType – Change from HFS to ZFS
  • Any of the other listed mpm allocation parameters to reflect attributes to be used for future ZFS allocations.
  1. Edit MSM/CSM Runtime SAMPLIB(DBINIT) and change the following parameters:
    1. mpmHlq – If dataset names changed with conversion
    2. mpmFilesystemType – Change from HFS to ZFS
  • Any of the other listed mpm allocation parameters to reflect attributes to be used for future ZFS allocations.
  1. If the conversion datasets involved the underlying CSM product file systems (where MSM/CSM was installed), you will need to update the BPXPRM entries to reflect the new Dataset names and new ZFS Filesystem Type. You will also want to add PARM(‘AGGRGROW’) to each ZFS mount statement to allow the datasets to be extended dynamically, as needed.
  2. When verification is complete, delete the exiting HFS datasets. These datasets could have been renamed by the BPXWH2Z utility, depending on the arguments used for the conversion.
  3. Appendix A – Sample ISPBATCH for BPXWH2Z utility
//*  PORT 22041                                                    
//*************************************************************    
//*    LICENSED MATERIALS - PROPERTY OF IBM                        
//*    5694-A01                                                    
//*    COPYRIGHT IBM CORP. 2002, 2008                              
//*                                                                
//*  THIS JCL WILL RUN THE BPXWH2Z(HFS TO ZFS MIGRATION)           
//*  CONVERSION TOOL AS AN ISPF BATCH JOB.                         
//*                                                                
//*  CAUTION: THIS IS NEITHER A JCL PROCEDURE NOR A COMPLETE       
//*  JOB.  BEFORE USING THIS JOB STEP, PLEASE INSPECT IT           
//*  CAREFULLY FOR ANY CHANGES THAT ARE NECESSARY TO MAKE IT       
//*  FIT FOR YOUR INSTALLATION'S NEEDS.                            
//*                                                                
//*  NOTES:                                                        
//*                                                                
//*  1. ADD THE JOB PARAMETERS TO MEET YOUR SYSTEM REQUIREMENTS    
//*                                                                
//*  2. RUN ONLY THE STEPS THAT ARE APPLICABLE TO YOUR             
//*     INSTALLATION.                                              
//*                                                                
//*  3. THIS JOB WILL COMPLETE WITH A COMPLETION CODE 0 IF         
//*     SUCCESSFUL, OR WITH A COMPLETION CODE 8 IF IT              
//*     ENCOUNTERS ANY ERROR WHILE RUNNING THE TOOL FOR            
//*     SINGLE HFS DATA SET MIGRATION.                             
//*                                                                
//*  4. FOR MULTIPLE HFS DATA SET MIGRATIONS, THIS JOB WILL        
//*     COMPLETE WITH A COMPLETION CODE 0 IF SUCCESSFUL, OR        
//*     WITH A COMPLETION CODE 8 IF NO MIGRATIONS WERE             
//*     SUCCESSFUL, OR WITH A COMPLETION CODE 4 IF ONE OR          
//*     MORE MIGRATION IS SUCCESSFUL, BUT ATLEAST ONE FAILED.      
//*                                                                
//*  5. CHECK THE JOB OUTPUT FOR EXECUTION INFORMATION             
//*     INCLUDING ERROR DETAILS.                                   
//*                                                                
//*  6. THE ZFS DATA SETS CANNOT BE PRE-ALLOCATED WHEN ISPF        
//*     BATCH JOB METHOD IS USED FOR BPXWH2Z CONVERSION TOOL.      
//*                                                                
//*  7. SYSEXEC DD SPECIFIES THE BPXWH2Z REXX EXEC LOCATION.       
//*                                                                
//*  8. SYSTSPRT DD SPECIFIES THE OUTPUT LOG.                      
//*                                                                
//*  9. SYSTSIN DD SPECIFIES THE ISPSTART CMD WITH PARMS.          
//*                                                                
//*  STATUS= HBB7750                                               
//*                                                                
//*  $P0=MEXXXXX   HBB7750  070910  PD2R: INITIAL ISPF BATCH JCL   
//*                                                                
//***************************************************************  
//ISPBTCH  EXEC PGM=IKJEFT01,                                      
//             DYNAMNBR=40,TIME=1440                               
//STEPLIB  DD DSN=ISP.SISPLPA,DISP=SHR,DCB=BLKSIZE=32760           
//         DD DSN=ISP.SISPLOAD,DISP=SHR                            
//         DD DSN=SYS1.MIGLIB,DISP=SHR                             
//         DD DSN=SYS1.SCBDHENU,DISP=SHR                           
//         DD DSN=ISF.SISFLOAD,DISP=SHR                            
//SYSTSIN DD *                                                     
ISPSTART CMD(BPXWH2Z -VC /HFS/ZFS/ YOUR.HLQ.FILE.SYSTEM.HFS )      
//SYSTSPRT DD SYSOUT=*                                             
//ISPLIST DD SYSOUT=A,DCB=(LRECL=121,BLKSIZE=1210,RECFM=FBA)       
//ISPLOG  DD SYSOUT=A,DCB=(LRECL=125,BLKSIZE=129,RECFM=VA)         
//SYSEXEC DD DSN=SYS1.SBPXEXEC,DISP=SHR                            
//*                                                                
//SYSUADS DD DSN=SYS1.UADS,DISP=SHR                                
//SYSLIB  DD DSN=SYS1.MACLIB,DISP=SHR                              
//SYSHELP DD DSN=SYS1.HELP,DISP=SHR                                
//ISPPLIB DD DSN=SYS1.SBPXPENU,DISP=SHR                            
//        DD DSN=ISP.SISPPENU,DISP=SHR                             
//ISPMLIB DD DSN=SYS1.SBPXMENU,DISP=SHR                            
//        DD DSN=ISP.SISPMENU,DISP=SHR                             
//ISPSLIB DD DSN=ISP.SISPSENU,DISP=SHR                          
//ISPTLIB DD DSN=SYS1.SBPXTENU,DISP=SHR                         
//        DD DSN=ISP.SISPTENU,DISP=SHR                          
//ISPPROF  DD DISP=NEW,UNIT=3390,SPACE=(CYL,(1,1,5)),           
//         DCB=(RECFM=FB,LRECL=80,BLKSIZE=3120)                 
//ISPTABL  DD DISP=NEW,UNIT=3390,SPACE=(CYL,(1,1,5)),           
//         DCB=(RECFM=FB,LRECL=80,BLKSIZE=3120)                 
//SDSFMENU DD DSN=ISF.SISFPLIB,DISP=SHR                                       

 

To use BPXWH2Z in general, that is, not being related to any specific product use this command from the TSO ready prompt:

ISPSTART CMD(BPXWH2Z -VC /HFS/ZFS/ YOUR.HLQ.FILE.SYSTEM.HFS )

File systems being converted should first be unmounted. 

If the file system dataset name such as YOUR.HLQ.FILE.SYSTEM.HFS is just a prefix HLQ for multiple file systems such as YOUR.HLQ.FILE.SYSTEM.HFS.* then they should all be unmounted. If YOUR.HLQ.FILE.SYSTEM.HFS represents just one file system then only one will be converted.

To convert HFS to ZFS manually.

First I allocated the ZFS file system in batch which gives me control using this JCL:

//DEFINRW  EXEC PGM=IDCAMS                                            
//SYSPRINT DD SYSOUT=*                                                
//SYSUDUMP DD SYSOUT=*                                                
//AMSDUMP  DD SYSOUT=*                                                
//SYSIN    DD *                                                       
  DELETE HLQ.HFS2ZFS.ZFS  CLUSTER                                 
                                                                      
  SET MAXCC=0                                                         
                                                                      
  DEFINE CLUSTER (             -                                      
  NAME(HLQ.HFS2ZFS.ZFS )     -                                    
  MANAGEMENTCLASS(MCMPT)        -                                     
  STORAGECLASS(SCMPT)       -                                         
  DATACLASS(DCMPT)       -                                            
  LINEAR CYL(500 10)            -                                     
  SHAREOPTIONS(3,3)            -                                      
                  )                                                   
/*                                                                    
//*                                                                   
//*-------------------------------------------------------------------
//*        Format the zFS aggregate  for RW zFS                       
//*        (compatibility mode aggregates)                            
//*-------------------------------------------------------------------
//*                                                                   
//FMTRW    EXEC PGM=IOEAGFMT,REGION=0M,                               
// PARM=('-aggregate HLQ.HFS2ZFS.ZFS  -compat')                   
//SYSPRINT DD SYSOUT=*                                                
//STDOUT   DD SYSOUT=*                                                
//STDERR   DD SYSOUT=*                                                
//SYSUDUMP DD SYSOUT=*                                                
//CEEDUMP  DD SYSOUT=*                                                
//*                                                                   

//ETNRWZFS EXEC PGM=IKJEFT01,REGION=4096K,DYNAMNBR=50 
//SYSTSPRT DD SYSOUT=*                                
//SYSTSOUT DD SYSOUT=*                                
//SYSTSIN  DD *                                       
MOUNT FILESYSTEM('HLQ.HFS2ZFS.ZFS') +             
TYPE(ZFS) MODE(RDWR) +                                
PARM('AGGRGROW')  +                                   
MOUNTPOINT('/plexc1/u/users/barra01/HFSZFS')          

 

Go into OMVS and do a cd to the path where the HFS file to be converted to ZFS is mounted. For example

cd /plexc1/u/users/barra01/HFS

An HFS file system HLQ.FILE.SYSTEM.HFS is mounted to /plexc1/u/users/barra01/HFS

 

The new ZFS is mounted to /plexc1/u/users/barra01/HFSZFS as can be seen in the JCL above.

After the cd to the HFS path:

 

pax -rw -peW -XCM . \               <<<hit enter

/plexc1/u/users/barra01/HFSZFS      <<< hit enter

It says running then changed to input. This did the conversion.

Now  HLQ.FILE.SYSTEM.HFS which is still HFS and it's ZFS equivalent of HLQ.HFS2ZFS.ZFS