Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

MQ Environment Variables

314 views
Skip to first unread message

Manu

unread,
Dec 13, 2010, 3:05:11 PM12/13/10
to
Hi,

We have the MQ installed and has been working good.. But, when we
login to oss for executing the MQ related commands, it says no such
command. The problem is eventhough we have correct environment
variable for MQ set in the TACLCSTM and WMQCSTM, the values are not
getting reflected in the OSS. Also, we have the PATH variable set in
the wmqcstm file, but eventhouh I run wmqcstm manually(it should
execute automatically), the values are not setting.. the ENV shows
some predefined values...

Can somebody guess what could be the issue..

thnx in advance

Keith Dick

unread,
Dec 13, 2010, 4:15:25 PM12/13/10
to

I do not know anything about MQ, so I can only suggest some things to check, based on general knowledge of OSS.

Which way do you "login to oss"? Do you use the OSH command from a TACL prompt, or do you login from the OSS login: prompt?

If you are logging in from the OSS login: prompt, then I imagine you must put appropriate environment setup commands into /etc/profile or the .profile file in your userid's home directory. I am nearly certain that nothing from TACLCSTM will be used during OSS login, and, assuming WMQCSTM is a Guardian file, I imagine the same is true for it.

If you are logging in from TACL using OSH, the descripton of OSH says it converts Guardian PARAMs into OSS environment variables, although it converts some special characters into underscores. It mentions that the size of an individual PARAM value is limited to 255 characters, and the total size of the PARAM names and values is limited to 1024 characters. I think those are the normal Guardian limits, so I doubt the problem is too many PARAMs.

If you are using OSH, you ought to be able to compare the PARAMs in Guardian with the OSS environment variables to see whether OSH is carrying them over correctly. Use the PARAM command with no arguments in TACL to show all the PARAMs and their values, then use the env command in OSS to see all the OSS environment variables.

As far as running wmqcstm manually, I found an IBM WebSphere MQ for HP NonStop Server, Version 5.3.1.1 README via a Google search, and at one point it says:

To establish the WMQ environment for an OSS shell session:

. wmqprofile

Note, that is using the dot command to run the file, and the file name is wmqprofile, not wmqcstm. Near that point in the document, it says that the wmqprofile file actually is in the var/mqm directory (should that be /var/mqm directory? I don't know).

I imagine you are expected to put the ". wmqprofile" command (or maybe the ". /var/mqm/wmqprofile" command) into your .profile file or into /etc/profile, but perhaps that is a wrong assumption.

If you actually were running the wmqprofile file in OSS (rather than the wmqcstm file that you said), maybe you did not run it via the dot command. If you did run it via the dot command, I don't know what the problem might be.

Bill Honaker

unread,
Dec 13, 2010, 8:30:46 PM12/13/10
to
Manu,

Can't guess, but...

Which version of MQ is installed? the 5.3 version (and later I
suspect) installs from OSS and makes settings in the .profile file for
the mqm.mgr user... but as I recall you had to change your
/etc/profile (or individual .profile file) manually. The manuals that
IBM wrote specifically for the NonStop are surprisingly good, give
them a look.

On Mon, 13 Dec 2010 12:05:11 -0800 (PST), Manu <with...@gmail.com>
wrote:

Joachim Schmitz

unread,
Dec 14, 2010, 2:15:29 AM12/14/10
to
Manu wrote:
> Hi,
>
> We have the MQ installed and has been working good.. But, when we
> login to oss for executing the MQ related commands, it says no such

This to me means you are using an OSS TELSERV Service and not the OSH
command from a TACL prompt, correct?

> command. The problem is eventhough we have correct environment
> variable for MQ set in the TACLCSTM and WMQCSTM, the values are not
> getting reflected in the OSS. Also, we have the PATH variable set in
> the wmqcstm file,

TACLCSTM is only used from TACL, so for it to take effect you'd need to get
to OSS via the OSH command from a TACL prompt. WMQCSTM has no meaning to
TACL nor OSS shell, so unless it is used inside TACLCSTM, it is not used at
all.

> but eventhouh I run wmqcstm manually(it should
> execute automatically), the values are not setting.. the ENV shows
> some predefined values...

Here I assume you are trying to execute WMQCSTM from an OSS Shell prompt. If
so: that ain't gonna work, if you want environment setting to be set, you'd
need to use the . (dot) command:

. ./mqmcstm

to advice the current shell to read (and obey) that file. If you just do a

./wmqcstm

You start a new shell, which reads that files and obesy it, just do exit at
EOF and leave you with nothing bein set in the original shell session.

> Can somebody guess what could be the issue..
>
> thnx in advance

You'd be better of to move those environment setting into the ~/.profile
file of the MQ user.
You can even combine this, by refering to the wmqcstm file in ~/.profile
(using the dot command mentioned above)
Or put it into /etc/profile, so everybody gets it, but I'd not.

What TACLCSTM in the users default subvol is for TACL, is .profile in the
users initial directory fo the OSS shell, i.e. it is indivilual to the user
and wWhat TACLLOCL in $SYSTEM.SYSTEM is to TACL, is /etc/profile to the OSS
shell, i.e. it gets used by everybody.
These files are not used by gtacl -p <prog> resp. OSH -p <prog>, i.e. not if
the -p option is used, but in all other cases.

Clear a mud?

Bye, Jojo

Manu

unread,
Dec 14, 2010, 2:57:16 AM12/14/10
to
On Dec 14, 12:15 pm, "Joachim Schmitz" <nospam.j...@schmitz-

Sorry for all the confusions...

I mistakenly type wmqprofile as wmqcstm. I will paste my
TACLCSTM,WMQCSTM and wmqprofil here.... (i used ./wmqprofile from the
oss as well).
Also, i cannot put the entries in the /etc as we have 2 MQ environment
in a server both refers to different locations.

$MQS01 INSTALL 4> fup copy taclcstm
PID: 7,156 $SYSTEM.SYS04.FUP
?TACL MACRO
== TACL created this file for your protection.
==
LOAD /KEEP 1/$MQS01.MQMACS.MQMACS
LOAD /KEEP 1/$AUDIT.PRODR.PROMPTER
==LOAD /KEEP 1/ $MQS01.INSTALL.SEARCH
PARAM MQDEFAULTPREFIX $MQS01
PARAM MQEMSEVENTS 127
==PARAM MQMACHINIFILE $MQS01.ZMQSSYS.MQSINI
PARAM MQRDF OFF
PARAM MQSNOAUT 1
PARAM SAVE-ENVIRONMENT ON
==
#SET #PMSEARCHLIST $SYSTEM.SYSTEM $SYSTEM.ZTCPIP &
$MQS01.ZWMQBIN $MQS01.ZWMQINC $MQS01.ZWMQSAMP #DEFAULTS [#defaults]
==
delete define =TCPIP^PROCESS^NAME
delete define =TCPIP^RESOLVER^NAME
==
add define =TCPIP^PROCESS^NAME,FILE $ZB31C
add define =TCPIP^RESOLVER^NAME,FILE $SYSTEM.ZTCPIP.RESCONF
==
PARAM HOME /usmqprd/var/mqm
==
OBEY $MQS01.ZWMQSAMP.WMQCSTM


$MQS01 INSTALL 6> fup copy $MQS01.ZWMQSAMP.WMQCSTM
$MQS01 INSTALL 6..
PID: 7,148 $SYSTEM.SYS04.FUP
PARAM MQNSKVARPATH /usmqprd/var/mqm
PARAM MQNSKOPTPATH /usmqprd/opt/mqm
ADD DEFINE =_RLD_LIB_PATH,CLASS SEARCH,SUBVOL0 $MQS01.ZWMQBIN
PARAM ^RLD^FIRST^LIB^PATH /usmqprd/opt/mqm/lib
PARAM MQNSKOPTPATH^INC^G $MQS01.ZWMQINC
PARAM MQNSKOPTPATH^BIN^G $MQS01.ZWMQBIN
PARAM MQNSKOPTPATH^LIB^G $MQS01.ZWMQBIN
PARAM MQNSKOPTPATH^SAMP^G $MQS01.ZWMQSAMP
PARAM SAVE-ENVIRONMENT ON

$MQS01 INSTALL 9> osh
PID: 7,410 $SYSTEM.SYS04.OSH
/usmqprd/var/mqm: cat wmqprofile
export MQNSKVARPATH=/usmqprd/var/mqm
export MQNSKOPTPATH=/usmqprd/opt/mqm
export _RLD_LIB_PATH=/usmqprd/opt/mqm/lib
export PATH=$PATH:/usmqprd/opt/mqm/bin:/usmqprd/opt/mqm/samp/bin
add_define =_RLD_LIB_PATH class=search subvol0=\$MQS01.ZWMQBIN
/usmqprd/var/mqm:


My problem is:

/usmqprd/var/mqm: ./wmqprofile
/usmqprd/var/mqm: mqver
/bin/-sh: mqver: not found
/usmqprd/var/mqm:

Manu

unread,
Dec 14, 2010, 3:06:22 AM12/14/10
to
> /usmqprd/var/mqm:- Hide quoted text -
>
> - Show quoted text -

Also, i have similar setup in a different server that works fine !!

Keith Dick

unread,
Dec 14, 2010, 3:07:43 AM12/14/10
to

Do you even read our answers?

That command

./wmqprofile

should be

. ./wmqprofile

Both I and Jojo told you that.

Manu

unread,
Dec 14, 2010, 3:07:56 AM12/14/10
to
On Dec 14, 12:57 pm, Manu <withm...@gmail.com> wrote:
> /usmqprd/var/mqm:- Hide quoted text -
>
> - Show quoted text -

PID: $Z4FR $MQS01.ZWMQBIN.MQVER
Name: WebSphere MQ
Version: 531.6 FP5316
CMVC level: WMQ-5-3-1-6
BuildType: IKAP - (Production)

Joachim Schmitz

unread,
Dec 14, 2010, 4:09:43 AM12/14/10
to
Manu wrote:
> On Dec 14, 12:15 pm, "Joachim Schmitz" <nospam.j...@schmitz-
<snip>
> My problem is:
>
> /usmqprd/var/mqm: ./wmqprofile

As I said: you need to use the . (dot) command

. ./wmqprofile

> /usmqprd/var/mqm: mqver
> /bin/-sh: mqver: not found
> /usmqprd/var/mqm:

Bye, Jojo

Manu

unread,
Dec 14, 2010, 8:06:30 AM12/14/10
to
On Dec 14, 2:09 pm, "Joachim Schmitz" <nospam.j...@schmitz-digital.de>
wrote:

That seems to be working..Thanks alot for the help.However, any idea
why this is not getting set automatically in one system, while it is
working fine in the other system...

Joachim Schmitz

unread,
Dec 14, 2010, 8:35:00 AM12/14/10
to
Manu wrote:
> On Dec 14, 2:09 pm, "Joachim Schmitz" <nospam.j...@schmitz-digital.de>
> wrote:
>> Manu wrote:
>>> On Dec 14, 12:15 pm, "Joachim Schmitz" <nospam.j...@schmitz- <snip>
>>> My problem is:
>>
>>> /usmqprd/var/mqm: ./wmqprofile
>>
>> As I said: you need to use the . (dot) command
>>
>> . ./wmqprofile
>>
>>> /usmqprd/var/mqm: mqver
>>> /bin/-sh: mqver: not found
>>> /usmqprd/var/mqm:
>>
>> Bye, Jojo
>
> That seems to be working..Thanks alot for the help.However, any idea
> why this is not getting set automatically in one system, while it is
> working fine in the other system...

most probably because the setup of these 2 machines is not identical. I
would bet that on the 'workine' system, these settings are done in
/etc/profile or ~/.profile (and if only by using that ". ./wmqprofile" in
there)

bye, Jojo

0 new messages