IBM DB2 Installation on Red Hat Enterprise Linux

0
1847

IBM DB2 database can be installed on Linux, UNIX or Window operating systems. We are going to install DB2 Version 10.1 on Red Hat Enterprise Linux Server from command interface. IBM DB2 is a next generation data platform for transactional and analytical operations.

Step 1 : Download IBM DB2 Package for Red Hat Linux from following URL. You can use IBM DB2 database for 90 days without any cost.

We have downloaded the package DB2_ESE_10_Linux_x86-64.tar.gz under /opt directory.

[root@Server opt]# ls
 DB2_ESE_10_Linux_x86-64.tar.gz

Step 2 : Extract IBM DB2 downloaded package as shown below.

[root@Server opt]# tar -xvzf DB2_ESE_10_Linux_x86-64.tar.gz

[root@Server opt]# ls
DB2_ESE_10_Linux_x86-64.tar.gz ese

Step 3 : Now install IBM DB2 Package

[root@Server opt]# cd ese
[root@Server opt]# ls
db2 db2ckupgrade db2_deinstall db2_install db2ls db2preregcheck db2setup ibm_im installFixPack n1pack
[root@Server ese]# ./db2_install

DBI1324W
 Support of the db2 install command is deprecated. For
 more information, see the DB2 Information Center.
 Default directory for installation of products - /opt/ibm/db2/V10.1
 **********************************************************
 Install into default directory (/opt/ibm/db2/V10.1) ? [yes/no]

yes (Press Enter)

Specify one of the following keywords to install DB2 products.

ESE
 CLIENT
 RTCL

Enter "help" to redisplay product names.
 Enter "quit" to exit.
 ***********************************************************
 ESE
 ***********************************************************
 Do you want to install the DB2 pureScale Feature? [yes/no]
 no

DB2 installation is being initialized.
 Total number of tasks to be performed: 46
 Total estimated time for all tasks to be performed: 1673 second(s)
 Task *1 start
 Description: Checking license agreement acceptance
 Estimated time 1 second(s)
 Task *1 end
 Task *2 start
 Description: Base Client Support for installation with root privileges
 Estimated time 3 second(s)
 Task *2 end
 Task *3 start
 Description: Product Messages - English
 Estimated time 13 second(s)
 Task *3 end
 Task *4 start
 Description: Base client support

.....

.....

.....

For more information see the DB2 installation log at

"/tmp/db2_install.log.12177".

Step 4 : Now check which DB2 packages are installed on your server. To check installed packages you can read log files (db2_install.log.xxxxx) under /tmp directory.

DB2 Setup log file started at:  Thu Feb 26 22:23:43 2015 IST
============================================================
Operating system information: Linux 2.6.32-220.el6.x86_64.#1 SMP Wed Feb x 08:03:13 EST 2015 x86_64
WARNING: Notification SMTP server has not been specified. Notifications cannot be 
sent to contacts in your contact list until this is specified. For more information
see the DB2 administration documentation.
Product to install:                        DB2 Enterprise Server Edition
Previously Installed Components:
Selected Components:
Base client support
Java support
SQL procedures
Base server support
Connect support
DB2 data source support
Spatial Extender server support
IBM Software Development Kit (SDK) for Java(TM)
DB2 LDAP support
DB2 Instance Setup wizard
Integrated Flash Copy Support
Spatial Extender client
Communication support – TCP/IP
Tivoli SA MP
Base application development tools
DB2 Update Service
Replication tools
Sample database source
DB2 Text Search
Informix data source support
First Steps
Installing: ESE_PRODUCT_SIGNATURE
Installing DB2 file sets :…….Success
DBI1514I  The DB2 High Availability (HA) scripts for the IBM Tivoli System 
Automation for Multiplatforms (SA MP) were successfully installed.
Explanation:
You need DB2 HA scripts to use SA MP with the DB2 HA feature.
These DB2 HA scripts are located at /usr/sbin/rsct/sapolicies/db2. 
The DB2 installer detects whether these DB2 HA scripts
need to be installed or updated.

User response:
No action is required.
Installing or updating DB2 HA scripts for IBM Tivoli System Automation for 
Multiplatforms (Tivoli SA MP) :…….Success
Executing control tasks :…….Success
Updating global registry :…….Success
Starting DB2 Fault Monitor :…….Success
Updating the db2ls link :…….Success
Registering DB2 licenses :…….Success
Setting default global profile registry variables :…….Success
Initializing instance list :…….Success
Registering DB2 Update Service :…….Success
Updating global profile registry :…….Success
Post Install Recommendations
—————————–
Required steps:
Set up a DB2 instance to work with DB2.
Optional steps:
To validate your installation files, instance, and database functionality,
run the Validation Tool, /opt/ibm/db2/V10.1/bin/db2val. For more information, 
see “db2val” in the DB2 Information Center.

Open First Steps by running “db2fs” using a valid user ID such as the DB2 instance 
owner’s ID. You will need to have DISPLAY set and a supported web browser in the 
path of this user ID.

Verify that you have access to the DB2 Information Center based on the choices you 
made during this installation. If you performed a typical or a compact installation,
verify that you can access the IBM Web site using the internet. If you performed a 
custom installation, verify that you can access the DB2 Information Center location
 specified during the installation.

Ensure that you have the correct license entitlements for DB2 products and features
installed on this machine. Each DB2 product or feature comes with a license certificate 
file (also referred to as a license key) that is distributed on an Activation CD, 
which also includes instructions for applying the license file. If you purchased 
a base DB2 product, as well as, separately priced features, you might need to 
install more than one license certificate. The Activation CD for your product or 
feature can be downloaded from Passport Advantage if it is not part of the physical
 media pack you received from IBM. For more information about licensing, search the 
Information Center (http://publib.boulder.ibm.com/infocenter/db2luw/v10r1/index.jsp) 
using terms such as “license compliance”, “licensing” or “db2licm”.

DB2 Setup log file finished at:  Thu x Feb 2015 10:25:26 PM IST

Step 5 : Now create db2 instance and fenced user.

[db2inst1@Server ~]# id db2inst1
uid=500(db2inst1) gid=500(db2igrp1) groups=500 (db2igrp1)

[db2inst1@Server ~]# id db2fenc1
uid=501(db2fenc1) gid=500(db2fgrp1) groups=500 (db2fgrp1)

Step 6 : Now Create db2 instance.

[root@Server instance]# ./db2icrt -a SERVER_ENCRYPT -p DB2_db2inst1 -s ese -u db2fenc1 db2inst1
DBI1446I  The db2icrt command is running, please wait.
DB2 installation is being initialized.
Total number of tasks to be performed: 4
Total estimated time for all tasks to be performed: 309 second(s)
Task #1 start
Description: Setting default global profile registry variables
Estimated time 1 second(s)
Task #1 end
Task #2 start
Description: Initializing instance list
Estimated time 5 second(s)
Task #2 end
Task #3 start
Description: Configuring DB2 instances
Estimated time 300 second(s)
Task #3 end
Task #4 start
Description: Updating global profile registry
Estimated time 3 second(s)
Task #4 end
The execution completed successfully.
For more information see the DB2 installation log at "/tmp/db2icrt.log.48480". 
DBI1070I  Program db2icrt completed successfully.

Step 8 : Create a Sample database.

[db2inst1@Server ~] db2 “create database sample”

Your IBM DB2 database is ready to use.

SHARE

LEAVE A REPLY