Você está na página 1de 55

IBM Software Group

Configuration Migration for


WebSphere Application Server
Paul Van Norman (vanno@us.ibm.com)
Vishavpal Shergill (vishavs@us.ibm.com)
WebSphere Application Server L2 Support
July 17, 2014

WebSphere Support Technical Exchange


IBM Software Group

Agenda
Introduction to Migration

Migration Process and Utilities

Migration Scenarios
Migration of Stand Alone server on same Machine using Migration Graphical
Tool
Migration of Federated cell to remote Machine using Command line

Rollback options

Common Issues

Summary - Things to remember

WebSphere Support Technical Exchange 2


IBM Software Group

Introduction to Migration

WebSphere Support Technical Exchange 3


IBM Software Group

Introduction to Migration
What is meant by configuration migration ?

Configuration migration is the process of upgrading a WebSphere


Application Server (WAS) installation to a newer major release

Migration leverages the existing configuration and applications and


migrates them to newest version environment

The previous version will still exist after migration completes

Configuration Migration Tools will not check compatibility of Application on


newer release

Application Migration Toolkit ( not covered in this WSTE) can be used to


check Application Compatibility Presentation text

WebSphere Support Technical Exchange 4


IBM Software Group

WebSphere Support Technical Exchange 5


IBM Software Group

Migration Process and Utilities

WebSphere Support Technical Exchange 6


IBM Software Group

Migration Process
WebSphere Application Server v8.5 supports migration from versions v6.0,
v6.1, v7.0 and v8.0

Migration process is per profile


In cell environment, you would migrate the dmgr profile first and then
other node profiles accordingly

v6.x, v7.x, v8.0 v8.5

WebSphere Support Technical Exchange 7


IBM Software Group

Migration Utilities
Configuration Migration Management Tool (CMMT) for WAS
v8.x (GUI)

Command Line
ManageProfiles
WASPreUpgrade
WASPostUpgrade

Note : Configuration Migration Utilities are to migrate from


older version to newer version. They cannot be used to migrate
same version from one host to another.

WebSphere Support Technical Exchange 8


IBM Software Group

Migration Scenarios

WebSphere Support Technical Exchange 9


IBM Software Group

Migration Scenarios
Migration of Standalone server on same machine
GUI or command line (We will cover it using GUI later in
this session)

Cell migration to remote machine


Command line only

In both Scenarios we migrate from WAS 7.0 to WAS 8.5

WebSphere Support Technical Exchange 10


IBM Software Group

Migration of Stand-alone server on same machine using Migration Graphical Tool

WebSphere Support Technical Exchange 11


IBM Software Group

Migration Wizard
Configuration Migration Management Tool (CMMT) for WAS
8.5

The migration wizard command is run from the WAS 8.5 bin
directory

Syntax:
app_server_root\bin\migration.[bat|sh]

WebSphere Support Technical Exchange 12


IBM Software Group

CMMT (WebSphere Configuration Toolbox) 1

WebSphere Support Technical Exchange 13


IBM Software Group

Existing profiles in v7.0

Creates a backup of your source


profile, it will be compressed and archived

WebSphere Support Technical Exchange 14


IBM Software Group

Select the output directory for Migrated profile configuration

Select a directory for trace file location, by default is Migration Output directory

WebSphere Support Technical Exchange 15


IBM Software Group

Create New Profile

Use Existing Profiles in v8.5

WebSphere Support Technical Exchange 16


IBM Software Group

We are choosing
to create new
profile

WebSphere Support Technical Exchange 17


IBM Software Group

WebSphere Support Technical Exchange 18


IBM Software Group

WebSphere Support Technical Exchange 19


IBM Software Group

Migrate object types from source to target configuration

WebSphere Support Technical Exchange 20


IBM Software Group

Summary of Migration

Commands can be generated based on options selected

WebSphere Support Technical Exchange 21


IBM Software Group

Commands generated during Graphical options


C:\IBM\WebSphere\AppServerJOBMGR\bin\backupConfig.bat
C:\IBM\WebSphere\Migration70to85\profilesBackup\MigrationBackup_AppSrv03_2014_
07_08T16_39_35_434.zip -nostop -profileName AppSrv03

C:\IBM\WebSphere\AppServer855_JDK7\bin\WASPreUpgrade.bat
C:\IBM\WebSphere\WSMigration\AppSrv03 C:\IBM\WebSphere\AppServerJOBMGR -
requireEmbeddedDBMigration true -traceString "Migration.Flow=finer:Migration.*=fine"
-traceFile
C:\IBM\WebSphere\WSMigration\AppSrv03\logs\WASPreUpgrade_2014_07_08T16_39_3
5_436.trace -oldProfile AppSrv03

C:\IBM\WebSphere\AppServer855_JDK7\bin\manageprofiles.bat -create -profileName


AppSrv09 -templatePath default -hostName vishavpal -nodeName vishavpalNode03

C:\IBM\WebSphere\AppServer855_JDK7\bin\WASPostUpgrade.bat
C:\IBM\WebSphere\WSMigration\AppSrv03 -oldProfile AppSrv03 -profileName AppSrv09
-scriptCompatibility true -replacePorts true -includeApps true -keepAppDirectory false -
traceString "Migration.Flow=finer:Migration.*=fine" -traceFile
C:\IBM\WebSphere\WSMigration\AppSrv03\logs\WASPostUpgrade_2014_07_08T16_39_
35_436.trace

WebSphere Support Technical Exchange 22


IBM Software Group

10

Backup of source Profile Complete

11

WASPreUpgrade Complete

WebSphere Support Technical Exchange 23


IBM Software Group

12

Profile Creation Complete

13

WASPostUpgrade Complete

WebSphere Support Technical Exchange 24


IBM Software Group

14

WebSphere Support Technical Exchange 25


IBM Software Group

Migration on remote machine using Command line

WebSphere Support Technical Exchange 26


IBM Software Group

Command Line Tools

CreateRemoteMigrJar

ManageProfiles

WASPreUpgrade

WASPostUpgrade

WebSphere Support Technical Exchange 27


IBM Software Group

Migration to remote machine (1 of 2)


Migrate WebSphere profiles to a new machine where the OS may be
different

Use the "WASPreUpgrade -machineChange true" command for cross


platform migrations

v8.5

v8.5

WebSphere Support Technical Exchange 28


IBM Software Group

Migration to remote machine (2 of 2)


The createRemoteMigrJar tool will package all required libraries need for
WASPreUpgrade command in a .zip archive

Do not have to install v8.x on old machine to run WASPreUpgrade

WASPreUpgrade command is obtained from the machine where


WebSphere v8.x is installed
v8.5

v8.5

v8.5

WebSphere Support Technical Exchange 29


IBM Software Group

Steps Deployment Manager Profile Migration


1. Create Deployment Manager profile in v8.5 install
./manageprofiles.sh
-create
-profileName Dmgr01
-templatePath \opt\WebSphereV85\profileTemplates\management
-serverType DEPLOYMENT_MANAGER
-nodeName DmgrNodeName
-cellName <v70versioncellName>
-hostName mydmgrhost.company.com

Note: cellName of Deployment Manager must be the same as source profile

WebSphere Support Technical Exchange 30


IBM Software Group

2. Create remoteMigration.jar file


To create the .jar file, from WAS85_HOME/bin/migration/bin run
createRemoteMigrJar.bat(sh) -targetDir <dir for the remote migration jar>
This creates the following file: WAS_V85_OS.arch_RemoteMigrSupport.zip.
For example: WAS_V85_windows.x86_RemoteMigrSupport.zip

Prepare the remote system for the WasPreUpgrade command.


Send the .jar file to the system where your source profile resides.
Extract the file to a temporary location.
Cd to the bin directory in the temporary location.
You are now ready to run the WASPreUpgrade command against the source
profile.

Note :You must create the remote migration .jar file on the same operating system
and architecture as you installed the source.

WebSphere Support Technical Exchange 31


IBM Software Group

3. Run the WASPreUpgrade command to save the v7.0 dmgr configuration to a


backup directory
<v85_tmpdir>/migration/bin/WASPreUpgrade.sh
/backup_source_host/v70tov85dmgr01
/opt/WebSphereV70
-oldProfile Dmgr01
-machineChange true

Check the WASPreUpgrade console output for "Failed with errors" or


"Completed with warnings"

NOTE: Look in the following logs for warnings or errors


backup_source_host/v70tov85dmgr01/logs/WASPreUpgrade.< timestamp >.log
backup_source_host/v70tov85dmgr01/logs/WASPreUpgrade.trace

WebSphere Support Technical Exchange 32


IBM Software Group

4. Use any archive tool to create a compressed file of the backup directory
Example:
cd /backup_source_host
./opt/WebSphereV70/java/bin/jar -cf v70tov85dmgr01.jar v70tov85dmgr01/

Move the archived file to the target machine

Create a directory on the target machine and extract the archived file to the
new directory
Example:
mkdir /backup_source_host
cd /backup_source_host
./opt/WebSphereV85/java/bin/jar xf v70tov85dmgr01.jar

WebSphere Support Technical Exchange 33


IBM Software Group

5. Run WASPostUpgrade on new v8.5 host server


/DMGR85_PROFILE/bin/WASPostUpgrade.sh
/backup_source_host/v70tov85dmgr01
-profileName Dmgr01
-keepDmgrEnabled TRUE
Specify -keepDmgrEnabled true when you run the WASPostUpgrade command in
a remote dmgr migration

Check the WASPostUpgrade console output for "Failed with errors" or "Completed
with warnings"

Note: Look in the following logs for warnings or errors

backup_source_host/v70tov85dmgr01/logs/WASPostUpgrade.<target profile
name>.<timestamp>.log
backup_source_host/v70tov85dmgr01/logs/WASPostUpgrade.<target profile name>.trace

WebSphere Support Technical Exchange 34


IBM Software Group

6. Stop and disable the deployment manager on the old host


Old name:
$PROFILE_ROOT/config/cells/cell_name/nodes/deployment_manager_
node_name/serverindex.xml
New name:
$PROFILE_ROOT/config/cells/cell_name/nodes/deployment_manager_
node_name/serverindex.xml_disabled

7. Start the new v8.5 Deployment Manager

8. Sync Old nodes with new v8.5 Deployment Manager

9. Deployment Manager is now successfully migrated

WebSphere Support Technical Exchange 35


IBM Software Group

For Node Migration


1. Create new Node in v8.5 using manageprofiles command
/V85_WAS_HOME/bin/manageprofiles.sh
-create -profileName AppSrv01
-templatePath /opt/WebSphereV85/profileTemplates/managed
-nodeName host1Node01

2. Copy remoteMigration jar file to Source Node and run waspreupgrade


(step2 in Deployment Manager Migration)

3. Copy and move the backup directory to New machine (step 4 for dmgr)

4. Stop and disable the nodeagent in v7.0 on the source machine


Old name:
$PROFILE_ROOT/config/cells/cell_name/nodes/node_X/serverindex.xml New
name:
$PROFILE_ROOT/config/cells/cell_name/nodes/node_X/serverindex.xml_disabled

WebSphere Support Technical Exchange 36


IBM Software Group

5. Run WASPostUpgrade for node migration on target machine


/V8.5_NODE_HOME/bin/WASPostUpgrade.sh
/filepath/migration_specific_backup
-profileName AppSrv01

Check the WASPostUpgrade console output for "Failed with errors" or


"Completed with warnings"
Note: Look in the following logs for warnings or errors:
backup_source_host/v70tov85appserv01/logs/WASPostUpgrade.<target
profile name>.<timestamp>.log
backup_source_host/v70tov85appserv01/logs/WASPostUpgrade.<target
profile name>.trace

6. Start migrated nodeagent

WebSphere Support Technical Exchange 37


IBM Software Group

Quick Summary
Install WAS v8.5 with latest fixpack on the target host
Create a new profile on the v8.5 WebSphere Application
Server
Use the createRemoteMigrJar from v8.5 to create a OS
specific Jar
Copy the new jar file to the v7.0 host and expand in temporary
directory
Use the WASPreUpgrade -machineChange true parameter to
create backup (distributed only not iSeries or zOS)
Compress the resulting backup directory and copy to target
host
Run WASPostUpgrade command from the new v8.x profile

WebSphere Support Technical Exchange 38


IBM Software Group

Rollback options

WebSphere Support Technical Exchange 39


IBM Software Group

Rolling back to original configuration

Rolling back a WAS ND Cell

Rolling back a Standalone Application Server

WebSphere Support Technical Exchange 40


IBM Software Group

Rolling back a WSAS ND Cell


1. Stop all of the servers and node agents that are currently running in the Version 8.5
environment
2. If Previous DMGR was disabled, perform one of the following actions (Note:
Disablement is the default)
a. If there is backup of previous deployment manager configuration restore it
b. If there is no back up of previous deployment manager configuration, use the
migrationDisablementReversal.jacl script from the previous version profile_root/bin
directory of the deployment manager
Example,
./wsadmin.sh -f migrationDisablementReversal.jacl -conntype NONE

If having issues, try to manually perform the steps in the script


From: profile_root/config/cells/cell_name/nodes/node_name
where node_name is the name of the deployment manager node to roll back.

There will be a serverindex.xml_disabled file in this directory, perform the following actions:
Delete or rename the serverindex.xml file
Rename the serverindex.xml_disabled file to serverindex.xml

WebSphere Support Technical Exchange 41


IBM Software Group

Rolling back a WSAS ND Cell (contd.)


3. Perform one of the following actions for each of the federated nodes that need to be rolled
back
a. If there is backup of old node, please restore it
b. If no backup back up taken then use migrationDisablementReversal.jacl script from
OLDVERSIONS_profile_root/bin directory of the federated node
Example,
./wsadmin.sh -f migrationDisablementReversal.jacl -conntype NONE
If you have trouble running the migrationDisablementReversal.jacl script, try manual steps.
From: profile_root/config/cells/cell_name/nodes/node_name where node_name is the federated node to
roll back
There will be serverindex.xml_disabled file in this directory, perform the following actions:
Delete or rename the serverindex.xml file
Rename the serverindex.xml_disabled file to serverindex.xml

4. Synchronize the federated nodes if they were ever running when the Version 8.5 deployment
manager was running
5. Delete the version 8.5 profile
6. Start the rolled-back deployment manager and its federated nodes v7.x environment

WebSphere Support Technical Exchange 42


IBM Software Group

Rolling back a Standalone application server


1. Stop all of the servers that are currently running in the version 8.5
environment
2. Perform one of the following actions to restore the v7.x /v6.x
configuration for the standalone application server
a. If there is backup of previous configuration restore it
b. If there is no backup Use the migrationDisablementReversal.jacl script from
the v7.x profile_root/bin directory of the standalone application server
Example,
./wsadmin.sh -f migrationDisablementReversal.jacl -conntype NONE

3. Delete the v8.5 profile for the standalone application server


4. Start the rolled-back standalone application server

WebSphere Support Technical Exchange 43


IBM Software Group

Common Issues

WebSphere Support Technical Exchange 44


IBM Software Group

Common Issues
WASPostUpgrade fails with DMGR profile
New DMGR cellName not same as old DMGR
Cell Name of DMGR has to match old environments Cell Name

WASPostUpgrade fails with node profile


New DMGR not started while doing node migration

Nodeagents not recognizing new DMGR


During WASPostUpgrade on nodes, tool trying to connect to old Deployment
Manager
Synch the old nodes to new DMGR before node migration

WebSphere Support Technical Exchange 45


IBM Software Group

Wrong Profile
WASPostUpgrade run without profileName option then default profile is used
Command fails
<Was_V70_AppServer>\bin> ./WASPreUpgrade.sh /backup70to85
/opt/WebSphere/AppSrv70
MIGR0104E: You must specify the currently installed WebSphere Application Server
directory name
MIGR0272E: The migration function cannot complete the command.
Execution of WASPreUpgrade from v7.0 WSAS_HOME/bin instead of v8
WAS_HOME
OutOfMemory on WASPostUpgrade
Using the changeMachine true parameter collects additional, shared files, and
places in migrated directory in the backup archive
Large number of applications
Increase heapsize for the WASPostUpgrade command using -javaoption for
example -javaoption -Xmx1024m

WebSphere Support Technical Exchange 46


IBM Software Group

Summary Things to Remember

WebSphere Support Technical Exchange 47


IBM Software Group

Things to remember
Before attempting migration, backup all source profiles completely

Both WASPreUpgrade and WASPostUpgrade must be executed from


WSAS v8.x (new version)

Install the new release with the same cell name and node name you are
migrating from, as either a deployment manager, or standalone profile

After WASPostUpgrade completes, the old deployment manager needs


to be stopped & disabled (automatic if on same host, manually if remote)

Start new deployment manager and manually synchronize all old


nodeagents before starting a node migration

Make sure ulimit for open files is 10000 or higher

WebSphere Support Technical Exchange 48


IBM Software Group

Things to remember (contd.)


Can migrate applications or config or both

Each Profile is migrated separately, starting with the deployment manager


in an Network Deployment environment

If migrating application verify applications will work on new versions as it is

Do not federate node, each node will automatically be federated during the
node(s) migration

You must create the remote migration .jar file on the same operating
system and architecture as you installed the source. Because the archive
that is generated contains operating system specific code, it only executes
on this architecture

WebSphere Support Technical Exchange 49


IBM Software Group

Things to remember (contd.)


V7.x / v8.0.x Jobmanager and Admin Agent can be migrated to v8.5.x
Key Points for JobManager
Migrate your job manager profiles to Version 8.5 before you migrate
managed base application servers and deployment manager
When migrating the managed base application server or managed
deployment manager in a flexible management environment, the node
names must be the same in Version 8.5 and previous releases
Run WASPostUpgrade immediately after WASPreUpgrade completes. As
part of WASPreUpgrade, a backup of the database is created. If you restart
the old job manager before running WASPostUpgrade, the database in the
backup and the database in the old job manager will be out of sync.

Plan, Test and Implement


WebSphere Support Technical Exchange 50
IBM Software Group

Websphere Application Migration Toolkit


Built on IBM Rational Software
Quickly and easily identifies application code changes
necessary for new code levels Education
Compatible for migrations from WAS version 5,6,7 to
version 7, 8, 8.5
Simplifies application migration from additional
application servers including Jboss and WebLogic

WebSphere Support Technical Exchange 51


IBM Software Group

What to send to Support when problem occurs


Provide details on Command used for Migration and what
stage migration is failing
If using Graphical provide screen shot from failure
Send the following for review
Complete Backup directory used during Migration
Collector tool output from source and destination
Details on Setup of Source and Target environment i.e.
local or remote migration and hardware involved

WebSphere Support Technical Exchange 52


IBM Software Group

Additional WebSphere Product Resources


Learn about upcoming WebSphere Support Technical Exchange webcasts, and access
previously recorded presentations at:
http://www.ibm.com/software/websphere/support/supp_tech.html

Discover the latest trends in WebSphere Technology and implementation, participate in


technically-focused briefings, webcasts and podcasts at:
http://www.ibm.com/developerworks/websphere/community/
Join the Global WebSphere Community:
http://www.websphereusergroup.org
Access key product show-me demos and tutorials by visiting IBM Education Assistant:
http://www.ibm.com/software/info/education/assistant

View a webcast replay with step-by-step instructions for using the Service Request (SR)
tool for submitting problems electronically:
http://www.ibm.com/software/websphere/support/d2w.html
Sign up to receive weekly technical My Notifications emails:
http://www.ibm.com/software/support/einfo.html

WebSphere Support Technical Exchange 53


IBM Software Group

Connect with us!

1. Get notified on upcoming webcasts


Send an e-mail to wsehelp@us.ibm.com with subject line wste
subscribe to get a list of mailing lists and to subscribe

2. Tell us what you want to learn


Send us suggestions for future topics or improvements about our
webcasts to wsehelp@us.ibm.com

WebSphere Support Technical Exchange 54


IBM Software Group

Questions

WebSphere Support Technical Exchange 55

Você também pode gostar