Upgrading a DB2® pureScale® server
to DB2 Version 10.5 on Linux and UNIX requires that you install a
new DB2 Version 10.5 copy and then manually upgrade your existing instances
and databases to this new copy.
Before you begin
Before you upgrade the DB2 server:
About this task
This upgrade task describes the steps to
upgrade to DB2 Version 10.5 pureScale server.
Restrictions
Procedure
To upgrade to DB2 Version 10.5 pureScale server:
- Log on to the DB2 server
as the instance owner.
- Disconnect all applications and users on
every member node. To get a list of all database connections for the
current instance, issue the LIST APPLICATIONS command.
If all applications are disconnected, this command returns the following
message:
db2 list applications
SQL1611W No data was returned by the Database System Monitor.
SQLSTATE=00000
To disconnect all applications and
users, use the FORCE APPLICATION command: db2 force application all
- Stop all command line processor sessions
by entering the following command in each session that was running
the command line processor:
db2 terminate
- When all applications and users are disconnected and all command line processor sessions are stopped,
stop the database manager instance:
db2stop
Note: The time that is needed for the db2stop command
to complete the action depends on the number of cluster caching facilities
(CFs) and members in the cluster (up to 10 minutes).
- If the db2stop command
is not successful and fails to stop the database manager instance
timeout due to new incoming connections, run the following command
to disconnect all user connections and stop the database manager
instance:
db2stop force
Ensure
that the db2stop force command completes successfully.
- Stop all instance processes in members and cluster caching
facilities (CFs) in any order by issuing the db2stop
instance on <hostname> command on any node, where hostname is
the name of each member or CF in the cluster.
- Install DB2 Version 10.5 by performing the following steps:
- Log on to the DB2 server
with root user authority.
- Put the cluster management software
into maintenance mode on all members and cluster caching facilities
(CFs) by issuing the following command from the pre-DB2 Version 10.5 installation path . This command stops the peer
domain services on all hosts and prevents it from restarting during
system maintenance. You can issue the following command
only one time on any one of the members or CFs in the cluster.
OLD_DB2_INSTALL_DIR/bin/db2cluster -cm -enter -maintenance -all
where OLD_DB2_INSTALL_DIR is
the pre-DB2 Version 10.5 installation path. For example, if you are upgrading
from DB2 Version 9.8 to DB2 Version 10.5, the OLD_DB2_INSTALL_DIR is specified
as /opt/IBM/db2/V9.8.
- Put the cluster file system into maintenance mode on
all members and CFs by issuing the following command from the pre-DB2 Version 10.5 installation path. This command stops all hosts
from accessing the cluster files system (GPFS™)
during system maintenance. You can issue the following
command only one time on any one of the members or CFs in the cluster.
OLD_DB2_INSTALL_DIR/bin/db2cluster -cfs -enter -maintenance -all
- Install DB2 Version 10.5 using the DB2Setup
wizard. Run the db2setup command and select
the Install New option on the Install
a Product panel to install a new copy of DB2 Version 10.5.
db2setup -l /tmp/db2setup.log -t /tmp/db2setup.trc
In the Set up a DB2 instance panel,
select the option Do not create a DB2 instance.
The DB2 installer still performs
the installation, but, you can create an instance at a later point
by running the db2icrt or db2isetup command. The DB2Setup wizard provides a clear
flow through which you can start a DB2 pureScale Feature
installation from one member and successfully setup a DB2 pureScale environment across
multiple members. The cluster management software and the cluster
file system software are also upgraded during the installation to
meet the V10.5 requirements.
For more information, see Install DB2 Version 10.5.
- Ensure that the GPFS cluster
is at the minimum release level by using the following steps:
- Use the mmlsconfig command to determine the
minimum release level and whether the usePersistentReserve attribute
is set to YES, as in the following example:
root@XXX:/> /usr/lpp/mmfs/bin/mmlsconfig minReleaseLevel,usePersistentReserve
minReleaseLevel 3.4.0.7
usePersistentReserve yes
If the minReleaseLevel value
is 3.5 or higher, or if usePersistentReserve is set
to NO, then go to step
f.
- Use the mmchconfig command to update the GPFS configuration information to
the most current format that is supported by your GPFS level, as in the following example:
/usr/lpp/mmfs/bin/mmchconfig release=LATEST
Verifying that all nodes in the cluster are up-to-date ...
Verifying GPFS is stopped on all nodes ...
mmchconfig: Command successfully completed
mmchconfig: Propagating the cluster configuration data to all
affected nodes. This is an asynchronous process.
- Verify that the release level is updated, by issuing the mmlsconfig command
again:
/usr/lpp/mmfs/bin/mmlsconfig minReleaseLevel
minReleaseLevel 3.5.0.7
- As a root user, take the cluster management
software out of maintenance mode by issuing the following command
from the pre-DB2 Version 10.5 installation path. You can issue the following
command only one time on any one of the members or CFs in the cluster.
OLD_DB2_INSTALL_DIR/bin/db2cluster -cm -exit -maintenance -all
Note: If
the old DB2 installation path
is of DB2
Version 10.1, you must take the cluster management
software out of maintenance mode by issuing the following command:
OLD_DB2_INSTALL_DIR/bin/db2cluster -cm -exit -maintenance
- Ensure that all of the db2mnt resource groups are online, by
issuing the lssam command as provided in the following
example:
lssam -s "Name like '%db2mnt%rg'"
Online IBM.ResourceGroup:db2mnt-db2sd-rg Nominal=Online
'- Online IBM.Application:db2mnt-db2sd-rs
|- Online IBM.Application:db2mnt-db2sd-rs:XXX
'- Online IBM.Application:db2mnt-db2sd-rs:YYY
If
any groups are reported as
Unknown, like in the following
example, then reenter and exit maintenance mode, as described in
step b and
step
f:
lssam -s "Name like '%db2mnt%rg'"
Unknown IBM.ResourceGroup:db2mnt-db2sd-rg Control=MemberInProblemState Nominal=Online
'- Online IBM.Application:db2mnt-db2sd-rs Control=MemberInProblemState
|- Online IBM.Application:db2mnt-db2sd-rs:XXX
'- Online IBM.Application:db2mnt-db2sd-rs:YYY
Note: In
this scenario, you need to repeat steps b and f only; you do not need
to repeat steps c, d, and e.
- As a root user, take the cluster file system software
out of maintenance mode by issuing the following command from the pre-DB2 Version 10.5 installation path.
OLD_DB2_INSTALL_DIR/bin/db2cluster -cfs -exit -maintenance -all
- As a root user, commit changes to the cluster file system
by issuing the following command from the DB2 Version 10.5 installation path. You can issue the following command
only one time on any one of the members or CFs in the cluster.
NEW_DB2_INSTALL_DIR/bin/db2cluster -cfs -commit
where NEW_DB2_INSTALL_DIR is
the DB2 Version 10.5 installation path. For example,
if you are upgrading from DB2 Version 9.8 to DB2 Version 10.5, the NEW_DB2_INSTALL_DIR is specified
as /opt/IBM/db2/V10.5.
- As a root user, commit changes to the
cluster management software by issuing the following command from
the DB2 Version 10.5 installation path. You can issue the following command
only one time on any one of the members or CFs in the cluster.
NEW_DB2_INSTALL_DIR/bin/db2cluster -cm -commit
where NEW_DB2_INSTALL_DIR is
the DB2 Version 10.5 installation path.
- As an instance owner, restart
the DB2 instance processes on
all members and CFs with updated resources for the cluster management
software and the cluster file system software by issuing the db2start
instance on <hostname> command only
one time on any one of the members or CFs in the cluster.
- Install all DB2 add-on
products that were installed in the DB2 copy
from which you are upgrading.
- Upgrade DB2 pureScale instances.
Refer to Upgrading DB2 pureScale instances.
- Upgrade databases. Refer to Upgrading databases.
What to do next
After you upgrade the DB2 server,
perform the recommended Post-upgrade tasks for DB2 servers such as
resetting the diagnostic error level, adjusting log space size, and
rebinding packages. In addition, verify that the upgrade of your DB2 server was successful.