Troubleshooting WebSphere MQ when connecting through Oracle Database gateway

oracle

Many times, you have the infrastructure team Install and setup WebSphere MQ in your servers and then as an Architect when you try to move data across servers through these MQs you face a lot of issues.

Here I am not going to talk about troubleshooting any specific errors, however I will tell you the steps to do generic troubleshooting for a WebSphere MQ and Oracle connection.

This article assumes that you access WebSphere MQ through the gateway.

Main items:

  1. Check if the DB Link in the DB is pointing to the tns correctly
  2. Check the tnsnames.ora
  3. Check the listener.ora – 2 entries described below
  4. Check if the init<SID> has the correct entries
  5. Check if Oracle user on the server has access to the MQM group.

You must use the same SID value in the tnsnames.ora file, the listener.ora file, and the GATEWAY_SID environment variable in the gateway initialization file for each gateway instance being configured.

  1. Check if your DBLINK is configured to the correct tns_name_entry.

CREATE [PUBLIC] DATABASE LINK dblink [CONNECT TO userid IDENTIFIED
BY password] USING ‘tns_name_entry’;

You can look in the tnsnames.ora to verify if we are using the same name or not.

  1. The tnsnames.ora should have a entry like this.

tns_name_entry=

(DESCRIPTION=

(ADDRESS=

(PROTOCOL=TCP)

(HOST=host_name)

(PORT=port_number)

)

(CONNECT_DATA=

(SID=gateway_sid)

)

(HS=OK)

)

The gateway has some of the same components as an Oracle database which includes

>>directory where the gateway software is installed

>>System identifier (SID)

>>and an Initialization file similar to the Oracle database initialization parameter file

 

The default SID values

are:

— dg4mqs

This is the default SID that is used when the gateway resides on the same system

as the WebSphere MQ software.

— dg4mqc

This is the default SID that is used when the gateway resides on a different system

than the WebSphere MQ software. In this case, the gateway functions as a remote

WebSphere MQ client.

The gateway and the DB talk to each other using Oracle Net. You will need to configure both, the gateway and Oracle

database to have Oracle Net communication enabled, by configuring the files tnsnames.ora and listener.ora

The gateway initialization file would be like (init<sid>.ora). The initialization file must be available when the gateway is started.

During installation, a default initialization file is created in

$ORACLE_HOME/dg4mq/admin/init<sid>.ora, on UNIX based systems where sid is the default SID of dg4mqs or dg4mqc.

3. Two entries must be added to the listener.ora file:

  • A list of Oracle Net addresses for the Oracle Net Listener to listen on
  • The gateway process that the Oracle Net Listener should start in response to incoming connection requests

If you are using Oracle Net and the TCP/IP protocol adapter, then the syntax of an

entry in the listener.ora file is:

LISTENER=

(ADDRESS_LIST=

(ADDRESS=

(PROTOCOL=TCP)

(HOST=host_name)

(PORT=port_number)

)

 

Entry for the Gateway in listener.ora

 

SID_LIST_LISTENER=

(SID_LIST=

(SID_DESC=

(SID_NAME=gateway_sid)

(ORACLE_HOME=gateway_directory)

(PROGRAM=driver)

)

)

4. The following entries needs to be in the initialization file (init<SID>.ora)

LOG_DESTINATION=log_file

QUEUE_MANAGER=manager_name

AUTHORIZATION_MODEL=auth_model

TRANSACTION_MODEL=tx_model

TRANSACTION_LOG_QUEUE=tx_queue_name

TRANSACTION_RECOVERY_USER=rec_user

TRANSACTION_RECOVERY_PASSWORD=rec_password

TRACE_LEVEL=0

MQSERVER=channel

MQCCSID=character_set

 

 

 

 

Advertisement

Ratan Tata; and why he might have lost some respect

Whatever has been happening with the Tata Group has been saddening. I am not sure who is right or wrong, but definitely the way the removal of Cyrus Mistry was handled has not been professional at all. The Chairman of a company deserves to know if the board is unhappy with him and he or she has the right to at least get some time before these decisions are taken.

The Chairman deserves some dignity and if you think otherwise then the decision to designate the person as chairman was wrong in the first place.  In both the cases the board was wrong. Some people would argue that once you know that you were wrong it’s better to take faster corrective actions. However we need to understand that the Market is not just driven by numbers, it’s also driven by emotions and sentiments, which has definitely taken a hit in this case.

Additionally this will also inculcate fear into the minds of other top leaders, it’s simple if he can do this with the chairman then who am I.

 And Ratan Tata might not be looked at with the same respect again.

When I read your post

When I read your posts, I feel like giving up my redundant job in SG and do some stuff which I can be proud of, however the fear of failure just lurks around and may be that’s the real difference between you and me.
I started my own company when I was 21 and I had no fear of any kind when I did that, I was still in college. We continued for 2 years, until I left them due to some financial concerns at my end as we needed to pump in money every month. The two of them are still my good friends and still run the company.
But now after so many years, there are so many questions to ask
1. Will I succeed?
2. Will I be able to maintain the same standard of life ?
3. Will I be able to give my son and daughter the thought – let’s do what we want to, because we can always go back to our dad and he will take care.
May be I am right or maybe I am wrong. What I need to do is keep trying for sure.

How to SSH to a VirtualBox guest externally through a host?

Faced a lot of issues when I was trying to harden Metasploitable-2. One of the things that I learned was ‘how to SSH into a VirtualBox host’. The Metasploitable cli is not upto the mark :(.

Below are the steps which worked for me. Thanks Google :).

Go into VirtualBox.
Select your Host and click on “Settings”

meta1

Click on Network –> Click on Advanced –> Click on Port Forwarding and then add the SSH entry as shown below.meta-2

Got into VM CLI and install SSH Server:

meta-3

sudo apt-get install openssh-server

Click OK and Save your settings. Reboot your VM.
Install Putty client and connect as shown below:

meta-4

Use your id/pwd when prompted.

 

Hope the steps are clear.

 

Fired

A Team or an individual does not perform well.
Who do you think is responsible.
The team member(s) or the Leader.

I think the responsibility comes from top to bottom – So does lot of other things (appreciation, power, salary etc.)
You cannot always put all the pressure of performance on the team.
There can be various reasons why a team is not performing.
And I think it’s the job of the manager or his leader to understand why this is happening and come up with a solution.

No doubt, firing can be one of those solutions, but you should have given ample time and taken all the circumstances and choices of that individual into perspective before you do that.

It’s a failure at the manager’s end also, if you are firing somebody, it also means that you were not able to motivate or lead that person (apart from all other performance reasons)

Again it’s easy said than done. However you just learn from your experiences and make sure you don’t do the same mistake again.

“A smart man makes a mistake, learns from it, and never makes that mistake again.”

Open your Minds – Remain a student

I went to a training today. it was only a one hr training. I was really surprised by the questions that were posted to the trainer.

People asking random questions.

People not ready to listen to the full conversation.

People trying to be over-smart.

People trying to be prove that they are better than the technology/trainer itself.

I was just observing, at some point I thought I will just stand and give a 5 min lecture as to why have we come to this training.

I realized that as we grow and age, we think that we know everything and more importantly the other person does not know anything.

As we grow, we don’t have the learning hat On. As if all the learning in the world has been done with.

The reason that we have come to this training is to learn. Then why don’t we

Listen

Try and Understand

Make sense

Learn as much as we can.

Most of the questions that were posted could have been answered by themselves if you wait till the end of the training.

Sometimes its good to be a student. I guess not sometimes but remain a student always 🙂

 

Business!!! What matters most … 3 steps

1 min read if you are not distracted 🙂

1. Become a customer to your own service and see what all would you want in your service. (Basically convince yourself first and make sure you are a hard customer)

2. Co-relate that (your service) directly to the P&L of your business and see how it works. Don’t pretend time is going to take care of it. Your timespan should be small enough (1-2 months max), so that you know quickly what is working and what is not working and can assimilate changes in the next cycle.

3. Think of new innovation or ideas and repeat the cycle (got to step 1).

Human Mind !!!

Are humans able to assimilate the data that is poured in front of them. I mean, I am not talking about like a ton of numerical results but just few simple facts. I guess it’s the same thing which GMAT calls as Critical Thinking :).

For .e.g.

Scenario 1 :

If I tell you that I don’t know much about some stuff and then tell you few things about it. What is final conclusion ?. Most of the times .. ahh well he doesn’t know that stuff very well.

Scenario 2:

If I tell you that I am an expert in something, and then tell you the same few things about it (the ones which I said in the above paragraph). What is the final conclusion? Well you think that he knows stuff.

Kind of a tricky game !

 

Why has Flipkart delayed the joining dates of new campus recruits?

Really disappointed by the way Flipkart has postponed the joining dates for IIM grads.

Firstly, if you had a restructuring plan in mind, you should not have gone ahead and made the offers for June ’16. Basically you withheld information related to the candidates. Once you had told them about the dates the students would have made an informed decision (trust me there would have been still some students who would have joined you to fulfill their passion to work with a startup and you would have got much more committed employees who were willing to sit idle for 6 months for you)

Secondly, INR 1.5 lac compensation is not fair enough to an IIM grad for 6 months.

Thirdly, Sitting idle for 6 months, will make the fresh IIM grads loose their momentum of learning and implementing ideas and thoughts, which they have been doing till now. It will only demoralize and demotivate them.

Suggestion to Flipkart:

Not sure how many offers you have made and what sort of financial burden this will add on to the firm, however I would suggest you to include the candidates in the ongoing Org restructure. This is exactly what you need, new people bringing in new and innovative ideas.

Its not just about, from the company perspective, paying them salary or from the candidate perspective not getting paid, but Its more about making use of amazing people who are available at your disposal, candidates implementing what they have learned from brilliant professors and from one of the worlds top leading MBA institute.

You can even try to negotiate to start them off asap as interns till Dec ’16, so at least they start working with the Organisation and will be up to speed by Dec.

If all the above fails, and going by the way IIM has taken up the issue, the Institute might call for a 2nd round of campus placement which will be good for the candidates, however will definitely leave a black spot for Flipkart.

Best of Luck to both of you !!!!