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 IndexWebSphere Message Broker Supportsetting up mqsiprofile in ant script for Windows

Post new topicReply to topic
setting up mqsiprofile in ant script for Windows View previous topic :: View next topic
Author Message
newpie
PostPosted: Sun May 21, 2017 10:01 pm Post subject: setting up mqsiprofile in ant script for Windows Reply with quote

Novice

Joined: 21 Jun 2012
Posts: 16

Hi,

I am working on ant script for mqsiapplybaroverride in IIB V10 and trying to set mqsiprofile as mentioned below:

Option1:

<exec executable="C:/Program Files/IBM/IIB/10.0.0.7/server/bin/mqsiprofile.cmd" resultproperty="exec.returnvalue" spawn="false">
</exec>
<exec executable="mqsiapplybaroverride" resultproperty="exec.returnvalue" spawn="false">
<arg value="-b"/>
<arg value="TEST.bar"/>
<arg line="-p buildproperties.txt"/>
</exec>

Option 2:

<exec executable="cmd" resultproperty="exec.returnvalue" >
<arg value="/c C:/Program Files/IBM/IIB/10.0.0.7/server/bin/mqsiprofile.cmd &amp; mqsiapplybaroverride -b TEST.bar -p buildproperties.txt"/>
</exec>

But none of these options are working fine and getting errors which convey that profile is not set.

(error:
[exec] Error: Could not find or load main class com.ibm.broker.config.util.
ApplyBarOverride
)



It works fine when I try running the mqsiprofile.cmd in command prompt and then try the ant script.Any pointers on how we can setup mqsiprofile and then run the mqsiapplybaroverride in the same <exec> of the ant script???


The only option I could think of is to have a new .bat file created(setup the mqsiprofile and then run the mqsiapplybaroverride) and run it from ant.
This approach is working fine but I don't want to have a custom .bat/script created and want to understand how we can set the profile from ant <exec> itself.

Appreciate any pointers on this
Back to top
View user's profile Send private message Send e-mail
iibanalyst
PostPosted: Wed Jun 27, 2018 5:39 pm Post subject: Re: setting up mqsiprofile in ant script for Windows Reply with quote

Newbie

Joined: 31 May 2018
Posts: 9

newpie wrote:
Hi,

I am working on ant script for mqsiapplybaroverride in IIB V10 and trying to set mqsiprofile as mentioned below:

Option1:

<exec executable="C:/Program Files/IBM/IIB/10.0.0.7/server/bin/mqsiprofile.cmd" resultproperty="exec.returnvalue" spawn="false">
</exec>
<exec executable="mqsiapplybaroverride" resultproperty="exec.returnvalue" spawn="false">
<arg value="-b"/>
<arg value="TEST.bar"/>
<arg line="-p buildproperties.txt"/>
</exec>

Option 2:

<exec executable="cmd" resultproperty="exec.returnvalue" >
<arg value="/c C:/Program Files/IBM/IIB/10.0.0.7/server/bin/mqsiprofile.cmd &amp; mqsiapplybaroverride -b TEST.bar -p buildproperties.txt"/>
</exec>

But none of these options are working fine and getting errors which convey that profile is not set.

(error:
[exec] Error: Could not find or load main class com.ibm.broker.config.util.
ApplyBarOverride
)



It works fine when I try running the mqsiprofile.cmd in command prompt and then try the ant script.Any pointers on how we can setup mqsiprofile and then run the mqsiapplybaroverride in the same <exec> of the ant script???


The only option I could think of is to have a new .bat file created(setup the mqsiprofile and then run the mqsiapplybaroverride) and run it from ant.
This approach is working fine but I don't want to have a custom .bat/script created and want to understand how we can set the profile from ant <exec> itself.

Appreciate any pointers on this



Below snippet in Ant Script worked for me. I had the same problem as you and I was looking for answers and found your question unanswered. So I thought I can share my findings.

mqsi_path = C:/Program Files/IBM/IIB/10.0.0.7/server/bin
bar.source = TEST.bar
bar.properties = buildproperties.txt

<exec executable="${mqsi_path}/mqsiprofile.cmd" spawn="false" logerror="true" failonerror="false">
<arg value="&amp;"/>
<arg value="mqsiapplybaroverride.bat" />
<arg value="-b" />
<arg value="${bar.source}" />
<arg value="-p" />
<arg value="${bar.properties}" />
<arg value="-r" />
</exec>
Back to top
View user's profile Send private message
Display posts from previous:
Post new topicReply to topic Page 1 of 1

MQSeries.net Forum IndexWebSphere Message Broker Supportsetting up mqsiprofile in ant script for Windows
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.