2

I'm trying to use mo74 library but I always get exception "System.TypeInitializationException,WebSphereMQ.".

Library is installed (I can get help by WMQ commands).

The link from where I downloaded it - http://www-01.ibm.com/support/docview.wss?uid=swg24017698 Configuration:

    Windows Server 2008R2
    PSVersion 2.0
    Broker Version 7.0.0.5

Also tried on Windows 7, PS 2.0, Broker 7.0.0.5, Windows Server 2012, PS 4.0, Broker 7.0.0.0 with same result.

After install I tried to add WebSphereMQ.dll to GAC

[Reflection.Assembly]::LoadWithPartialName("System.EnterpriseServices") | Out-Null 
[System.EnterpriseServices.Internal.Publish] $publish = new-object  System.EnterpriseServices.Internal.Publish
$publish.GacInstall(<<FullFilePathToTheDll>>)

But it didn't help.

Full exception:

PS C:\Windows\system32> Get-WMQQueue SYSTEM.DEFAULT.LOCAL.QUEUE
Get-WMQQueue : The type initializer for 'IBM.WMQ.Nmqi.BindingsNmqiMQ' threw an exception.
At line:1 char:13
+ Get-WMQQueue <<<<  SYSTEM.DEFAULT.LOCAL.QUEUE
+ CategoryInfo          : NotSpecified: (:) [Get-WMQQueue], TypeInitializationException
+ FullyQualifiedErrorId : System.TypeInitializationException,WebSphereMQ.GetWMQQueue

Thanks for answers in advance!

7
  • Shot in the dark but you don't mention the architecture of the running PowerShell instance. The installation appears to be x86 architecture. Are you running a 32-bit shell? Commented May 25, 2015 at 11:37
  • Matt, it is 64-bit operation system, for execute script I used Windows PowerShell (x86) Commented May 25, 2015 at 13:16
  • You didn't mention having any MQ components installed. What's the output when you run dspmqver -a? Commented May 25, 2015 at 14:44
  • Can you please post the complete exception stack? Commented May 25, 2015 at 14:51
  • Shashi, added to the question text in main theme - "Full exception". Commented May 25, 2015 at 15:45

1 Answer 1

1

The problem have been solved in the new version of the driver. Link - http://www-01.ibm.com/support/docview.wss?uid=swg24017698

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.