|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Retrieving hostname using ESQL [Solved] |
« View previous topic :: View next topic » |
Author |
Message
|
Hari |
Posted: Sat May 15, 2004 4:14 pm Post subject: Retrieving hostname using ESQL [Solved] |
|
|
 Centurion
Joined: 21 Nov 2002 Posts: 117 Location: USA
|
Hi all,
Is it possible to retrieve the hostname of the machine on which the broker is running using ESQL?
Any help will be appreciated.
Regards,
Hari
Last edited by Hari on Fri Jun 11, 2004 10:45 am; edited 1 time in total |
|
Back to top |
|
 |
jefflowrey |
Posted: Sun May 16, 2004 3:13 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
Not that I know of. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
kirani |
Posted: Sun May 16, 2004 10:37 pm Post subject: |
|
|
Jedi Knight
Joined: 05 Sep 2001 Posts: 3779 Location: Torrance, CA, USA
|
You can write a plug-in node to do this. _________________ Kiran
IBM Cert. Solution Designer & System Administrator - WBIMB V5
IBM Cert. Solutions Expert - WMQI
IBM Cert. Specialist - WMQI, MQSeries
IBM Cert. Developer - MQSeries
|
|
Back to top |
|
 |
smdavies99 |
Posted: Mon May 17, 2004 2:09 am Post subject: Already Done |
|
|
 Jedi Council
Joined: 10 Feb 2003 Posts: 6076 Location: Somewhere over the Rainbow this side of Never-never land.
|
The GetENV Plugin node already has the ability to get environment variables. However, hostname is not in the standard list so you need to add a little bit to the .profile of the user who is going to run WMQI(unix)
$ HOST=`hostname`
$ export HOST
$ echo $HOST
ummagumma
$
Then in a compute node following the GETENV Plugin, you can then extract the value with a bit of ESQL. Something like:-
set OutputRoot.XML.Hostname = InputRoot.ENV.HOST;
This plugin is/was available as a support pack (IA06) _________________ WMQ User since 1999
MQSI/WBI/WMB/'Thingy' User since 2002
Linux user since 1995
Every time you reinvent the wheel the more square it gets (anon). If in doubt think and investigate before you ask silly questions. |
|
Back to top |
|
 |
JT |
Posted: Mon May 17, 2004 5:37 am Post subject: |
|
|
Padawan
Joined: 27 Mar 2003 Posts: 1564 Location: Hartford, CT.
|
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
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
|
|
|
|