DB2 Tools: An Introduction to the Bare Bones of using DB2 Effectively.

Introduction:

In this series of articles, we shall be discussing the various tools available in DB2 for effectively performing tasks pertaining to a number of situations.

In this article we shall be exploring the various tools available for DBAs and Developers.

To begin with, we have command line options as well as GUI tools made available.
The best part about DB2 is that it has a common code-base which makes it work on any platform, thereby giving DBAs and Developers a unified experience and ease of management.

We shall learn about the following tools.

Part 1

Command Line Tools

Development Tools

General Administration Tools

Part 2

Information

Monitoring Tools and finally

Setup Tools

The Command Line Tools consists of the following tools.

The Command Editor
The Command Window
The Command Line Processor

The Command Editor: This is a GUI based tool where one can type in SQL statements and get the results of the underlying query. This is similar to the Query Analyzer of SQL Server. Shown below is the figure of the Command Editor. 


The Command Window and Command Line Processor: This is a CUI based interface where one can directly type in the db2 commands. For you command line loversJ this is definitely a treat. Please note the Command Window is only available on the Microsoft Windows Platform.

The following figure represents the Command Line Processor Interface

In order to invoke the DB2 Command Window or DB2 Command Line Processor,
type in the following commands in the command prompt accordingly.

DB2 Command Window: db2cw
DB2 Command Line Processor: db2cmd



We shall move on to the Development Tools Section. We all are aware that no database is complete without a rich feature set of development tools.

The Database developer or DBA can benefit from using the following two tools available. They are:

The Development Center.

The Project Deployment Tool.

The Development Tool: This is the center for all Development activities relating to Stored Procedure development and User Defined Functions. 

This powerful tool will allow one to develop Stored Procedures in SQL or JAVA.
The User Defined Functions can be created in SQL, XML, Websphere MQ and OLEDB.

The following are some of the cool features of the Development Center.

It comes with an integrated debugger with real time step-into features.

It has the capability to deploy your stored procedures within the Development Environment and changes are reflected immediately in the Control Center.


The following figure below shows the Development center.



You can launch the Development center with the following command.
db2dc

We shall next take a look @ the Project Deployment Tool.

The projects that we have created in the Development Center can be exported directly to the Control Center or using the Project Deployment Tool.


The Deployment Tool screen looks like the figure shown below.



The deployment tool can be launched by typing the following command

db2dcdpl 


We shall now explore the General Administration tools.

The General Administration Tools consists of the following tools for DB2 Administration.

They are:

The Control Center: This is the master control for all your DBA activities in the DB2 Universe. The control center will allow DBAs to create Database Objects, Users and Groups and help establish connectivity between the local and remote DB2 Databases. You can invoke the control center by typing the following command. 

db2cc

The Journal: The journal is basically a center for managing and troubleshooting errors. It helps track the errors.

The Replication Center: This is the center that helps DBAs replicate their DB2 Databases from one Database Server location to another. To start the Replication Center, you can run the following command

db2rc

The Task Center: The task center allows one to automate tasks. Whenever there is little or no database activity, you can automate a task of creating backups for your databases using the task center. To start the Task Center, you can run the following command

db2tc


This completes part 1 of this article.

In Part 2, we shall explore the Information Tools, Monitoring Tools and finally finish it by exploring the Setup Tools.



Part II – Information Tools, Monitoring Tools and Setup Tools

Information Tools: The Information Tools consists of the following sections.

Information Center: This is the help documentation for the DB2 Database. To invoke the Information Center (locally), type in the following command

db2ic

Check for DB2 Updates: This consists of the tool that will update DB2 in the form of FixPaks. It is based on Installshield.

We shall next explore the last two sections.

Monitoring Tools: These tools help in diagnosing various problems and finding out a work around for the problems.

The following tools are:

Event Analyzer: The event analyzer is a tool that helps track events in the database through an event monitoring software, built-in to DB2. These are then reported into a log file.

The Health Center: The Health Center as the name indicates maintains stability for your DB2 Databases. In the event of a Memory usage or during a particular backup phase, the database state becomes inconsistent sometimes. In order to troubleshoot this problem, the Health center will help one in determining a solution and restore the state back to normal. You can either of the following states, Unavailable or Normal. 

The Indoubt Transaction Manager: These can help resolve issues regarding database transactions and help in determining the problem and coming out with alternative solutions to the problem. 

The Memory Visualizer: This is a very beneficial tool when it comes to Memory Management of the Database. Once can view which object, or series of SQL statements have been consuming memory and can be optimized accordingly.

The Activity Monitor: This monitoring software that helps in tuning performance and resources consumed. This tool helps in diagnosing most of the application related problems.


And finally we move on to the

Setup Tools:

First Steps: These are the main tools needed in order to setup DB2 for the very first time.

Configuration Assistant: This helps users to connect to remote DB2 Databases.

Register Visual Studio Add-Ins: This tool is needed for Registering DB2 Tools for .NET and Visual Studio 6.0.


This completes our journey of DB2 Tools. In the next series, we shall explore various options for Developing VS.NET 2005 Applications using DB2 Add-Ins for .NET 2.0 


Please send us your valuable feedback to

anilm001@gmail.com




Added on August 21, 2007 Comment

Comments

Post a comment