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 Java / JMS » Binding files.

Post new topic  Reply to topic
 Binding files. « View previous topic :: View next topic » 
Author Message
Hanuman
PostPosted: Mon Sep 11, 2006 8:06 pm    Post subject: Binding files. Reply with quote

Voyager

Joined: 28 Aug 2006
Posts: 89

Hi,
I have got .SCP files with me.
Now i need to run the JMSAdmin utility to create the bindings file.

Can any one help in step by step operation to do this on solaris.
Because i am new to this.And doing for the first time
I have installed WEbsphere 5.3 on solris.

Thanks in advance.

Parag
Back to top
View user's profile Send private message
elvis_gn
PostPosted: Mon Sep 11, 2006 8:24 pm    Post subject: Reply with quote

Padawan

Joined: 08 Oct 2004
Posts: 1905
Location: Dubai

Hi Parag,

Do not double post.

Have you read any documentation, have you tried anything...are u getting some error ?

Regards.
Back to top
View user's profile Send private message Send e-mail
Hanuman
PostPosted: Mon Sep 11, 2006 8:34 pm    Post subject: Reply with quote

Voyager

Joined: 28 Aug 2006
Posts: 89

Sorry for double posting ,

I need to this sort of something
The bindings file create process involves 2 steps.
1. Create a SCP file that lists the queues u need and binds that to a specific JNDI name
2. Run the JMSAdmin utility to create the bindings file.

dont no what specific commands to follow in order to this.
I am new this websphere.

We have installed mq series on solris server.

Pls help me out in this.

With regards
Parag

p.s: u can direclty send mail to parag.jog@tcs.com
Back to top
View user's profile Send private message
elvis_gn
PostPosted: Mon Sep 11, 2006 8:41 pm    Post subject: Reply with quote

Padawan

Joined: 08 Oct 2004
Posts: 1905
Location: Dubai

Hi Parag,

Try this

Regards.
Back to top
View user's profile Send private message Send e-mail
Hanuman
PostPosted: Mon Sep 11, 2006 9:25 pm    Post subject: Reply with quote

Voyager

Joined: 28 Aug 2006
Posts: 89

Thanks for the quick reply.

Right now i trying to do this this things Steps to configure JMS support:
1. In the command window, change to the JMS directory (for example, /mq_install_dir/java/bin).
2. The JMSAdmin command utility, provided with MQ JMS support, requires that the correct INITIAL_CONTEXT_FACTORY value and PROVIDER_URL be specified. To verify these values, edit the JMSAdmin.config file according to the edition of WebSphere you have installed:
o AE:
1. Locate the line specifying the INITIAL_CONTEXT_FACTORY and ensure that its value is set to: com.ibm.ejs.ns.jndi.CNInitialContextFactory
Locate the line specifying the PROVIDER_URL and ensure that its value is set to:
iiop://localhost/
PROVIDER_URL=iiop://localhost/
o AEd:
Locate the line specifying the INITIAL_CONTEXT_FACTORY and ensure that the value is set to:
com.sun.jndi.fscontext.RefFSContextFactory
Locate the line specifying the PROVIDER_URL and ensure that the value is set to:
file:/directory_path
PROVIDER_URL=file:/C:/JNDI-Directory
The directory_path is the location of the external naming information. You must create this directory and update the information on the PROVIDER_URL line with the fully qualified directory path name.

1. Ensure that the directory named here exists.
The following are examples for different operating systems:
Win2k/NT - PROVIDER_URL=file:///C:/JNDI-Directory
UNIX - PROVIDER_URL=file:////tmp/JNDI
3. Save the JMSAdmin.config file.
4. Edit your JMSAdmin script as follows to ensure that it uses the version of Java provided by WebSphere and includes additional directories in its run time:

1. Prepend the following path onto the Java call (where WAS_HOME is the location of your WebSphere/AppServer installation):
2. WAS_HOME/java/jre/bin

3. Provide the following directive to the Java run time as an option:
1. Windows:
2. -Djava.ext.dirs=WAS_HOME\java\lib;
3. WAS_HOME\java\jre\lib\ext;
4. WAS_HOME\lib;
mqm_install_dir\java\lib
5. UNIX:
6. -Djava.ext.dirs=WAS_HOME/java/lib:
7. WAS_HOME/java/jre/lib/ext:
8. WAS_HOME/lib:
mqm_install_dir/java/lib
5. Before running any Java client accessing MQ Series, you need to add an entry to your java.library path to find the necessary libraries. Run the following before attempting to run the JMSAdmin tool:
PATH=%PATH%;mqm_install_dir\java\lib (Windows)
export LIB_PATH=$LIB_PATH:mqm_install_dir/java/lib (AIX)
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:mqm_install_dir/java/lib (Solaris)
6. Enter the following command to run the supplied script:
JMSAdmin -cfg JMSAdmin.config < WAS_HOME/Enterprise/samples/messaging/src/PtoP/JMSppSetup.scp
After running, verify the output contains no errors.

I am done with first 3 steps but where can i find in order Edit your JMSAdmin script as follows to ensure that it uses the version of Java

I am right path i guess.
Back to top
View user's profile Send private message
elvis_gn
PostPosted: Mon Sep 11, 2006 9:48 pm    Post subject: Reply with quote

Padawan

Joined: 08 Oct 2004
Posts: 1905
Location: Dubai

Hi Parag,

This is what I use:
Quote:
INITIAL_CONTEXT_FACTORY=com.sun.jndi.fscontext.RefFSContextFactory

PROVIDER_URL=file:/C:/JNDIConfig


Parag wrote:
I am done with first 3 steps but where can i find in order Edit your JMSAdmin script as follows to ensure that it uses the version of Java
Right click the bat file and edit....you should find it there...though I have never had to do that....it automatically picks a jre from the Environment variables....simply try running the JMSAdmin.bat, see if it is working...

Regards.
Back to top
View user's profile Send private message Send e-mail
Hanuman
PostPosted: Mon Sep 11, 2006 11:04 pm    Post subject: Reply with quote

Voyager

Joined: 28 Aug 2006
Posts: 89

PROVIDER_URL=file:/C:/JNDIConfig

Is this path where JNDIConfig is present.

But in my case it is /opt/mqm/java/bin/JNDIConfig.

Now if i want to use JNI then i need to comment out
PROVIDER_URL=file:/C:/JNDIConfig
INITIAL_CONTEXT_FACTORY=com.sun.jndi.fscontext.RefFSContextFactoryRight.

Now how will do this
Prepend the following path onto the Java call (where WAS_HOME is the location of your WebSphere/AppServer installation):
WAS_HOME/java/jre/bin

3. Provide the following directive to the Java run time as an option:
Windows:
-Djava.ext.dirs=WAS_HOME\java\lib;
WAS_HOME\java\jre\lib\ext;
WAS_HOME\lib;
mqm_install_dir\java\lib
UNIX:
-Djava.ext.dirs=WAS_HOME/java/lib:
WAS_HOME/java/jre/lib/ext:
WAS_HOME/lib:
mqm_install_dir/java/lib

4. Before running any Java client accessing MQ Series, you need to add an entry to your java.library path to find the necessary libraries. Run the following before attempting to run the JMSAdmin tool:
PATH=%PATH%;mqm_install_dir\java\lib (Windows)
export LIB_PATH=$LIB_PATH:mqm_install_dir/java/lib (AIX)
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:mqm_install_dir/java/lib (Solaris)
5. Enter the following command to run the supplied script:
JMSAdmin -cfg JMSAdmin.config < WAS_HOME/Enterprise/samples/messaging/src/PtoP/JMSppSetup.scp
After running, verify the output contains no errors.

pls help in changing this file
Back to top
View user's profile Send private message
vennela
PostPosted: Tue Sep 12, 2006 5:11 am    Post subject: Reply with quote

Jedi Knight

Joined: 11 Aug 2002
Posts: 4055
Location: Hyderabad, India

First of all:
Is this an existing directory? I mean is this directory already created. JMSAdmin will not create it for you. You will have to create it before running the JMSAdmin tool
/opt/mqm/java/bin/JNDIConfig

Also make sure it is like

PROVIDER_URL=file:///opt/mqm/java/bin/JNDIConfig

Put all the jars under /opt/mqm/java/lib in CLASSPATH.

P.S. I deleted your other post
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Hanuman
PostPosted: Tue Sep 12, 2006 5:34 am    Post subject: Reply with quote

Voyager

Joined: 28 Aug 2006
Posts: 89

No problem on deleting the other post..............
Is this an existing directory? I mean is this directory already created.
ya its an exhisting created ......... .when i insatlled mq series it got installed by default.

JMSAdmin will not create it for you. You will have to create it before running the JMSAdmin tool
/opt/mqm/java/bin/JNDIConfig

i have update the classpath but still i get the error
Exception in thread "main" java.lang.NoClassDefFoundError: com/ibm/mq/jms/admin/JMSAdmin

Pls help me out

Thanks in advance..............

With regards
parag
Back to top
View user's profile Send private message
vennela
PostPosted: Tue Sep 12, 2006 6:59 am    Post subject: Reply with quote

Jedi Knight

Joined: 11 Aug 2002
Posts: 4055
Location: Hyderabad, India

Quote:
when i insatlled mq series it got installed by default.

I am pretty sure it won't get created when you install MQ.
/opt/mqm/java/bin will be created but not the JNDIConfig.
Anyway, double check it.

Inorder to set CLASSPATH
Issue ls -l /opt/mqm/java/lib/*.jar
Then do,
export CLASSPATH=/opt/mqm/java/lib/com.ibm.mqjms.jar:.......(insert all the above jars).....:$CLASSPATH

Hope this helps
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » IBM MQ Java / JMS » Binding files.
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.