Author |
Message
|
CharMick |
Posted: Tue Sep 04, 2007 10:43 am Post subject: Amqmdnet.dll and 2035 |
|
|
Newbie
Joined: 30 Aug 2007 Posts: 3
|
I'm trying to develop a tool that allows my end users to select a queue manager from a list and put/get messages. The tool is intended to support multiple testing environments so the user will have a need to be able to change the queue manager frequently. I have developed a simple prototype app in VB.net (don't laugh.....) using the amqmdnet.dll. Problem is that when I configure the MQEnvironment settings (Port, channel, hostname, etc...) and attempt to connect to the remote queue manager I am getting a 2035, MQRC_NOT_AUTHORIZED. I do not get this same error when using the MQXA200 ActiveX component but I cannot use the ActiveX component for this solution because it requires the user to change the MQSERVER environment variable to point to a different queue manager.
Do I have to have a userid/password in MQM group for my app to be able to connect using amqmdnet.dll?
Code snippet:
Try
MQEnvironment.Hostname = "205.11.64.9"
MQEnvironment.Channel = "CDL1ASY.CLIENT"
MQEnvironment.Port = 1415
myQManager = New MQQueueManager(sQueueManager)
Catch ex As Exception
MsgBox("Unable to create connection to Queue Manager: " + sQueueManager + vbCrLf + "Error Text: " + ex.Message.ToString)
End Try _________________ Chuck |
|
Back to top |
|
 |
fjb_saper |
Posted: Tue Sep 04, 2007 1:50 pm Post subject: Re: Amqmdnet.dll and 2035 |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
CharMick wrote: |
Do I have to have a userid/password in MQM group for my app to be able to connect using amqmdnet.dll?
Code snippet:
Try
MQEnvironment.Hostname = "205.11.64.9"
MQEnvironment.Channel = "CDL1ASY.CLIENT"
MQEnvironment.Port = 1415
myQManager = New MQQueueManager(sQueueManager)
Catch ex As Exception
MsgBox("Unable to create connection to Queue Manager: " + sQueueManager + vbCrLf + "Error Text: " + ex.Message.ToString)
End Try |
No your user does not have to be in the mqm group.
However it would be beneficial to set a user on the mcauser of the channel and have that user be in an AUTHORIZED group for the transactions it is attempting to do on the qmgr....
The other alternative is to authorize all your client userids by putting them into the authorized group...
IIRC the ActiveX component allowed you to run as user xyz...
Enjoy  _________________ MQ & Broker admin |
|
Back to top |
|
 |
RogerLacroix |
Posted: Tue Sep 04, 2007 8:50 pm Post subject: |
|
|
 Jedi Knight
Joined: 15 May 2001 Posts: 3264 Location: London, ON Canada
|
|
Back to top |
|
 |
CharMick |
Posted: Mon Sep 10, 2007 7:13 am Post subject: |
|
|
Newbie
Joined: 30 Aug 2007 Posts: 3
|
Thanks for the replies. I have a large number of end users that will need to be able to make use of the tool I am developing so it may not be practical to add all of them to an authorized group. I will probably have a single user added and allow the application to connect using this user.
I did not see a property in the ActiveX that allowed the user to be changed. Can you tell me where this is located? I thought the ActiveX would only use the ID of the logged-in user....
THanks, again. _________________ Chuck |
|
Back to top |
|
 |
jefflowrey |
Posted: Mon Sep 10, 2007 11:13 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
You want, at a minimum, to have your application use a specific channel to talk to the queue manager.
You want your MQ Admin to, at a minimum, set an MCAUser on that channel to a specific, known user that the MQ Admin has authorized as they feel appropriate.
Your MQ Admin likely wants you to implement the SSL features of MQ in your program, as well.
You always want to talk about 2035s with your MQ admin.
You always want to discuss your high level design with your MQ admin. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
CharMick |
Posted: Mon Sep 10, 2007 1:57 pm Post subject: |
|
|
Newbie
Joined: 30 Aug 2007 Posts: 3
|
Can you be my MQ Admin? You are much friendlier...
Seriously, I found that my issue is that I do not have a valid Userid on the box that hosts the QManager I am trying to hit. Once that userid was created on the box and my ID was added to an MQ group I was allowed to connect and go on my merry way...
I have to say that it has been more challenging than I expected to get this far....the APIs are not terribly well documented and the access to the QManagers was not obvious.
Thanks for your help. You were all correct....I just underestimated the difficulty in gaining access.
Thanks, again. _________________ Chuck |
|
Back to top |
|
 |
jefflowrey |
Posted: Mon Sep 10, 2007 2:09 pm Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
CharMick wrote: |
Can you be my MQ Admin? You are much friendlier... |
That may only be because I'm not your MQ Admin...
CharMick wrote: |
I just underestimated the difficulty in gaining access. |
Which is why you maybe should have talked to your MQ Admin first... Actively seeking their advice and assistance (whether you need it or not) may be a good way to make them friendlier. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
|