Your Ad Here

IBM AIX/UNIX system storage administration ksh/perl scripting

Monday, March 09, 2009

JFS to JFS2 conversion for rootvg

JFS to JFS2 conversion for rootvg

Note: Please use this procedure on your own risk.

Pre-req and notes
Ensure that the 64-bit kernel is the active kernel.
Confirm with the command “bootinfo –K”

I have tested these conversion steps on an AIX 5.3 system.
JFS2 was introduced with AIX 5.1 so these steps should work with AIX 5.1 and higher.

Note from the past: in 2003 (JFS2 had been available since 2001 but wasn’t as “stable” as it is now) - I had tested these steps in reverse order (JFS2 to JFS) and they worked successfully.


JFS to JFS2 Conversion steps
1. Perform a mksysb backup of the system (using either NIM, DVD-RAM or tape). This step performs two important actions – it runs the mkszfile command (which updates /image.data) and also provides the ability to undo the JFS to JFS2 conversion.

2. Make a backup of 3 files:


/bosinst.data
/image.data
/etc/filesystems

3. Modify these 3 files as follows:
/bosinst.data
Look for the following 2 lines

ENABLE_64BIT_KERNEL = Default
CREATE_JFS2_FS = Default

Change them to read:

ENABLE_64BIT_KERNEL = yes
CREATE_JFS2_FS = yes

/image.data
In the lv_data section of the file - change all occurrences of the string “jfs” to “jfs2”
In the fs_data section of the file – change each new JFS2 filesystem stanza from:

fs_data:
FS_NAME= /usr
FS_SIZE= 7340032
FS_MIN_SIZE= 3714768
FS_LV= /dev/hd2
FS_FS= 4096
FS_NBPI= 4096
FS_COMPRESS= no
FS_BF= false
FS_AGSIZE= 8

To read:
     fs_data:
FS_NAME= /usr
FS_SIZE= 7340032
FS_MIN_SIZE= 3714768
FS_LV= /dev/hd2
FS_JFS2_BS= 4096
FS_JFS2_SPARSE= yes
FS_JFS2_INLINELOG= no
FS_JFS2_SIZEINLINELOG= 0
FS_JFS2_EAFORMAT= v1
FS_JFS2_QUOTA= no
FS_JFS2_DMAPI= no
FS_JFS2_VIX= no

/etc/filesystems

For all of the rootvg filesystems - change occurrences of the string “jfs” to “jfs2”

4. Create another mksysb of the system but ensure that the –i flag is not used for the mksysb command. (TIP: If the –i flag is used then mkszfile will run again and will erase all of the custom changes made to the /image.data file)

5. Restore this mksysb (created in step 4) on the system and when the system comes up all of the rootvg filesystems will now be using JFS2 (run the mount command to confirm).

No comments:

Labels

Blog Archive

BlogCatalog