Wednesday, December 7, 2011

db2top on windows - quick tip

I recently spoke with a customer who liked db2top alot and inquired if he could run it on Windows. I told him that while it couldn't be run directly, it could be launched from a machine that supports db2top (unix,linux,aix or a vmware running unix/linux/) and attach to the windows database remotely.

I told him I'd seen an article referencing these steps and that he would likely find the instructions if he googled this. After searching for the link to give that to him, I could no longer find that posting. So, here is a quick note on how to do this.

In my example a have a linux machine running redhat from which I'm launching db2top.

1) First, catalog the remote windows database using both the
db2 catalog tcpip and db2 catalog database commands.

These catalog commands are run on the linux machine.

Here is my example:

db2 catalog tcpip node W2003 remote server 50000

(where is the IP address of the Windows database server I'd like to monitor and 50000 is the port, W2003 is an arbitrary name I gave my node.)

db2 catalog database sample at node W2003

2) Then, launch db2top from your linux machine using the -n nodename -u userid -p password.

My example again:

db2top -d sample -n W2003 -u db2admin -p ibmdb2

And, your monitoring your Windows Db2 database using db2top. (remotely from your linux/unix machine.)

I hope you found this tip helpful. I'm sorry I can't give the original author credit for posting this.
If you'd like to learn more about db2top, I've found the following Blog postings from Keith McDonald quite helpful.