Recently, I received an inquiry on reducing the size of the
installation media for WebSphere Portal 8. An administrator had
downloaded ~17GB of
installation media consisting of:
- IBM WebSphere Portal
- IBM WebSphere Application Server ND
- IBM WAS Supplements
- IBM WAS FP005
- IBM WAS FP005 Supplements
This was simply too much data
to transmit or maintain as they conducted installations in the field.
So I created the user story below and sought a way to reduce the
installation media's size as much as possible.
An operations team must package an installable version of WebSphere Portal. Since internet access at install time is not guaranteed, the team needs a "self-contained" installation media with minimal size. The target platform(s) is known; hence, the installation media reflects only the required platform(s).
I settled on using the IBM
Packaging Utility - specifically the pucl command
line tool. The goal was to
reduce the above media to: 1) a specific platform 2) only required
features/components. To do this, I used the command line tool
located in the Packaging Utility to create a batch script. I'll
explain some of the sections.
First, I locate the IBM Installation Manager repositories
that contain the product packages. Each repository is defined by the
respository.config file. I've defined each repository required for
the WebSphere Portal stack.
REM IIM Repositories (Base and/or Fixes)
set PORTAL=C:\WPS8_Media\Portal
set WAS_ND=C:\WPS8_Media\WAS
set WAS_ND_FIX=C:\WPS8_Media\Fixes\WAS
set WAS_SUPPLEMENTS=C:\WPS8_Media\Supplements
set WAS_SUPPLEMENTS_FIX=C:\WPS8_Media\Fixes\Supplements
set REPOSITORIES=%PORTAL%, %WAS_ND%, %WAS_ND_FIX%, %WAS_SUPPLEMENTS%, %WAS_SUPPLEMENTS_FIX%
I then print out the packages located by the Packaging
Utility.
REM Print the list of packages found
echo IBM Packages Found
"%pucl_cmd%" listAvailablePackages -repositories "%REPOSITORIES%"
REM Detailed information such as display name and platform
REM "%pucl_cmd%" listAvailablePackages -repositories "%REPOSITORIES%" -long -showPlatforms
This outputs the following packages:
com.ibm.websphere.PORTAL.SERVER.v80_8.0.0.20120421_0828com.ibm.websphere.ND.v80_8.0.3.20120320_0536com.ibm.websphere.BASE.v80_8.0.5.20121022_1902com.ibm.websphere.BASETRIAL.v80_8.0.5.20121022_1902com.ibm.websphere.DEVELOPERS.v80_8.0.5.20121022_1902com.ibm.websphere.DEVELOPERSILAN.v80_8.0.5.20121022_1902com.ibm.websphere.EXPRESS.v80_8.0.5.20121022_1902com.ibm.websphere.EXPRESSTRIAL.v80_8.0.5.20121022_1902com.ibm.websphere.ND.v80_8.0.5.20121022_1902com.ibm.websphere.NDDMZ.v80_8.0.5.20121022_1902com.ibm.websphere.NDDMZTRIAL.v80_8.0.5.20121022_1902com.ibm.websphere.NDTRIAL.v80_8.0.5.20121022_1902com.ibm.websphere.APPCLIENT.v80_8.0.0.20110503_0200com.ibm.websphere.IHS.v80_8.0.0.20110503_0200com.ibm.websphere.PLG.v80_8.0.0.20110503_0200com.ibm.websphere.PLUGCLIENT.v80_8.0.0.20110503_0200com.ibm.websphere.WCT.v80_8.0.0.20110503_0200com.ibm.websphere.APPCLIENT.v80_8.0.5.20121022_1902com.ibm.websphere.APPCLIENTILAN.v80_8.0.5.20121022_1902com.ibm.websphere.IHS.v80_8.0.5.20121022_1902com.ibm.websphere.IHSILAN.v80_8.0.5.20121022_1902com.ibm.websphere.PLG.v80_8.0.5.20121022_1902com.ibm.websphere.PLGILAN.v80_8.0.5.20121022_1902com.ibm.websphere.PLUGCLIENT.v80_8.0.5.20121022_1902com.ibm.websphere.PLUGCLIENTILAN.v80_8.0.5.20121022_1902
Each package has for format packageId_version. My
installation media consists of the base product as well as fixpacks.
So you'll see com.ibm.websphere.ND.v80_8.0.3.20120320_0536 and
com.ibm.websphere.ND.v80_8.0.5.20121022_1902. The default WAS
installation bundled with Portal is 8.0.0.3, but this is superseded by
the other package listed, which is WAS 8.0.0.5. Technically, we no
longer need the 8.0.0.3 version, and the Packaging Utility will take
care of this in the next step.
Next, I list only those packages that will be contained in
the "self-contained" installation. For example, I do not
list com.ibm.websphere.APPCLIENT.v80_8.0.5.20121022_1902, which
removes the WebSphere Application Server Client. I also leave out the
package's version. This enables the Package Utility to incorporate
the latest version available in the repositories.
REM IIM Packages to be copied (uses the latest version available)
set PORTAL_PAK=com.ibm.websphere.PORTAL.SERVER.v80
set WAS_ND_PAK=com.ibm.websphere.ND.v80
set WAS_PLUGIN_PAK=com.ibm.websphere.PLG.v80
set IHS_PAK=com.ibm.websphere.IHS.v80
The OS and architecture settings define which media goes
into the "self-contained" installation. I'm creating a
Windows only installation. The list of available OS and architecture
codes are below. Note that I REMarked the command
"%pucl_cmd%" listAvailablePackages -repositories
"%REPOSITORIES%" -long -showPlatforms. The -showPlatforms
flag will also list the installation media's platforms. You may want
to run this command to confirm that the listed packages support the
target architecture.
REM Specify the target platform and operating system
set OS=win32
set ARCH=x86
Values
for the
os
and
arch
attributes
os Values | arch Values |
---|---|
aix | ppc
ppc64 |
hpux | ia64
ia64_32 PA_RISC PA_RISC64 |
linux | ppc
ppc64 s390 s390x x86 x86_64 |
os400 | ppc
ppc64 |
solaris | sparc
sparc64 x86 x86_64 |
win32 | x86
x86_64 |
zos | s390
s390x |
Specify the output folder for the "self-contained"
installation.
REM Target package location
set TARGET=target_%OS%_%ARCH%
I then use the copy command to create the new installation
media. The -preview flag allows me to first test the process, which
would fail on error halting the script.
REM Test that the copy command succeeds
echo Preparing to Copy
"%pucl_cmd%" copy %PORTAL_PAK% -preview -repositories "%REPOSITORIES%" -platform os=%OS%,arch=%ARCH% -target %TARGET% -acceptLicense -showProgress -sP
"%pucl_cmd%" copy %WAS_ND_PAK% -preview -repositories "%REPOSITORIES%" -platform os=%OS%,arch=%ARCH% -target %TARGET% -acceptLicense -showProgress -sP
"%pucl_cmd%" copy %WAS_PLUGIN_PAK% -preview -repositories "%REPOSITORIES%" -platform os=%OS%,arch=%ARCH% -target %TARGET% -acceptLicense -showProgress -sP
"%pucl_cmd%" copy %IHS_PAK% -preview -repositories "%REPOSITORIES%" -platform os=%OS%,arch=%ARCH% -target %TARGET% -acceptLicense -showProgress -sP
echo Copying to Target
"%pucl_cmd%" copy %PORTAL_PAK% -repositories "%REPOSITORIES%" -platform os=%OS%,arch=%ARCH% -target %TARGET% -acceptLicense -showProgress -sP
"%pucl_cmd%" copy %WAS_ND_PAK% -repositories "%REPOSITORIES%" -platform os=%OS%,arch=%ARCH% -target %TARGET% -acceptLicense -showProgress -sP
"%pucl_cmd%" copy %WAS_PLUGIN_PAK% -repositories "%REPOSITORIES%" -platform os=%OS%,arch=%ARCH% -target %TARGET% -acceptLicense -showProgress -sP
"%pucl_cmd%" copy %IHS_PAK% -repositories "%REPOSITORIES%" -platform os=%OS%,arch=%ARCH% -target %TARGET% -acceptLicense -showProgress -sP
That leaves me with a "self-contained"
installation that I can use in Installation Manager, which can be
installed and recorded as a response file to script future silent
installations. Most importantly, the installation media is reduced from ~17GB to 2.8GB.
Now for some notes:
- The script basically does "de-platforming" and "de-packaging". It's intended to reduce the install size. "De-languaging" is omitted.
- Future fixpacks or versions would require modifying the script and creating a new package. Since the script uses the package ID and does not include the version, you can download the new fixpack or version, add the repository, and re-run. The script should simply include the most recent by default.
- The script does not utilize the "fixes" feature of the utility. Fixes are the patches (APARs) for products.
- With some more effort, you could likely create a script that downloads the latest product version, includes fixes, and creates the installation. Think of this as an "install snapshot" of the latest and greatest.