ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » IBM MQ API Support » Connect to remote MQServer via Client

Post new topic  Reply to topic
 Connect to remote MQServer via Client « View previous topic :: View next topic » 
Author Message
Nroblex
PostPosted: Mon Apr 28, 2008 2:15 am    Post subject: Connect to remote MQServer via Client Reply with quote

Novice

Joined: 15 Apr 2008
Posts: 11

Hello MQexperts

I have a perhaps simple question for you. I would be very happy if someone could give me a hint what is wrong.

I have developed a C# client application and I have a MQ server installed on my laptop. Everything works fine and I can connect to the queuemanager "PMC" without problem.

Now I instead want to connect to a remote server on a given IP address. I Have information about channelname and Queuemanagername and I also have a key file (SSL) . I do the following:

MQEnvironment.Hostname = "IPADRESS";
MQEnvironment.Port = 1414;
MQEnvironment.Channel = "CHANNELNAME" ;

MQEnvironment.SSLKeyRepository="Path.to.Keyfile"
MQEnvironment.SSLCipherSpec = "NULL_MD5"

MQQueueManager qmngr = new MQQueueManager("ManagerName");

I get the response "NOTFOUND". ??
If I just provide Ipadress, channelname and portname I get the following answer : MQRC_Q_MGR_NOT_AVAILABLE

I do not understand this.

Please help!

Many thanks in advance

//Nroblex
Back to top
View user's profile Send private message
Vitor
PostPosted: Mon Apr 28, 2008 2:33 am    Post subject: Re: Connect to remote MQServer via Client Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

Nroblex wrote:
I have developed a C# client application and I have a MQ server installed on my laptop. Everything works fine and I can connect to the queuemanager "PMC" without problem.


Was this connection achieved using a client or a server lib?

Nroblex wrote:
If I just provide Ipadress, channelname and portname I get the following answer : MQRC_Q_MGR_NOT_AVAILABLE


Am I correct in assuming this occurs if no SSL information is set?

I would search the forum for posts regarding 2059 errors (the numeric code of your error). It's perfectly possible that your code is fine, and other factors are causing the error.

IHMO the first thing to try is to telenet to the port MQ is listening on in the remote box. If you can't establish the telnet session, your app won't be able to either.

Look through the forum for other tips. This is a very common, often discussed error.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
Nroblex
PostPosted: Mon Apr 28, 2008 2:45 am    Post subject: Reply with quote

Novice

Joined: 15 Apr 2008
Posts: 11

Thanks for the answer!

"Was this connection achieved using a client or a server lib? "
How do I know that? On my laptop I have installed a developer license of MQ server. I also installed the clientsoftware.

"Am I correct in assuming this occurs if no SSL information is set?"
Yes that is right. Otherwise, if I provide SSL key, I get "NOTFOUND" error.

I tried to telnet to the server on port 1414 but I was denied.

I also made this test:

I tried to change the ipadress to my local on my laptop, to connect to my local MQ server, and I created a serverchannel using the MQ Explorer.

Then I tried to connect to my local queuemanager providing ip-adress and channelname. To my surprice I get the same error "MQRC_Q_MGR_NOT_AVAILABLE"

Any more hints ??

//Nroblex
Back to top
View user's profile Send private message
Vitor
PostPosted: Mon Apr 28, 2008 3:02 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

Nroblex wrote:
How do I know that?


You'd know that by knowing if you linked your application with the client dll or the server dll


Nroblex wrote:
I tried to telnet to the server on port 1414 but I was denied.


I think you've found your problem.

Or at least a problem. Sounds like a firewall to me.

Nroblex wrote:
I tried to change the ipadress to my local on my laptop, to connect to my local MQ server, and I created a serverchannel using the MQ Explorer.

Then I tried to connect to my local queuemanager providing ip-adress and channelname. To my surprice I get the same error "MQRC_Q_MGR_NOT_AVAILABLE"


I'm not surprised. I bet your laptop has a firewall running (unless you're a very trusting soul).

Firstly, ensure your application is linked with the client libraries. Then ensure that the means by which you're providing ip address & channel name (which you don't specify) are correct. Then ensure you can telnet (as before) to your local queue manager. Then ensure your application can connect to your local queue manager.

Then take another crack at connecting to the remote box.

Also review the forum (as suggested) for previous 2059 error posts.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
Nroblex
PostPosted: Mon Apr 28, 2008 3:42 am    Post subject: Even more confused ? Reply with quote

Novice

Joined: 15 Apr 2008
Posts: 11

I used the qmqmdnet as reference in my project ("IBM\Websphere MQ\bin") I suppose this is the server lib ? By using this I can use the IBM.WMQ namespace in my application, is that wrong ?

What I want to do is connect my client to a remote server.

If I use the IBM.XMS namespace in "IBM\Message Service Client for .NET\tools\lib\IBM.XMS.dll" is that correct then ? Connecting the clientapplication to the server.?

What is better? What do I have to do?

//Nroblex (the newbie)
Back to top
View user's profile Send private message
Vitor
PostPosted: Mon Apr 28, 2008 3:58 am    Post subject: Re: Even more confused ? Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

Nroblex wrote:
What is better? What do I have to do?


Neither is better, one is better for you. Each has it's place; for a simple example a server side app can only connect to a queue manager running on the same box as the app so can't do what you describe, but a client app can't participate in XA transactions. It's all about your design.

You should focus first on why you can't telnet to your respective targets; that's not going to help you. Then spend some time with the Using .NET documentation which will help with the various connection and other options that you have.

The Clients manual may also be of assistance.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
RogerLacroix
PostPosted: Mon Apr 28, 2008 7:30 pm    Post subject: Reply with quote

Jedi Knight

Joined: 15 May 2001
Posts: 3264
Location: London, ON Canada

Hi,

The same problem and solution is here:
http://www.mqseries.net/phpBB2/viewtopic.php?t=42432

Regards,
Roger Lacroix
Capitalware Inc.
_________________
Capitalware: Transforming tomorrow into today.
Connected to MQ!
Twitter
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » IBM MQ API Support » Connect to remote MQServer via Client
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.