Author |
Message
|
mq_crazy |
Posted: Thu Nov 11, 2004 11:30 am Post subject: Start queue manager in HP-UX |
|
|
 Master
Joined: 30 Jun 2004 Posts: 295
|
I have MQ 5.3 CSD07 installed in HP-UX box, whats happening is whenever we reboot the box i have to start the queue manager and listener manually, is there anyway that i can set it up to start the queue manager with the system and how?? please explain in detail as i am new to HP-UX environment. Thank You |
|
Back to top |
|
 |
csmith28 |
Posted: Thu Nov 11, 2004 11:39 am Post subject: |
|
|
 Grand Master
Joined: 15 Jul 2003 Posts: 1196 Location: Arizona
|
Does HP/UX have an /etc/inittab or /etc/rc.d _________________ Yes, I am an agent of Satan but my duties are largely ceremonial. |
|
Back to top |
|
 |
mq_crazy |
Posted: Thu Nov 11, 2004 11:55 am Post subject: |
|
|
 Master
Joined: 30 Jun 2004 Posts: 295
|
as i said that i am very ignorant of HP-UX. To check whether i got those i typed cd /etc/inittab and cd /etc/rc.d i got not a directory and not found error. I typed them at my prompt:
[color=red]mqm@atln4002:/home/mqm>[/color] |
|
Back to top |
|
 |
mq_crazy |
Posted: Thu Nov 11, 2004 11:57 am Post subject: |
|
|
 Master
Joined: 30 Jun 2004 Posts: 295
|
What is the command that i need to put in the startup script for the HP-UX, as my unix administrator said that she will take care of inserting it if i give the command that starts the queue manager |
|
Back to top |
|
 |
csmith28 |
Posted: Thu Nov 11, 2004 12:13 pm Post subject: |
|
|
 Grand Master
Joined: 15 Jul 2003 Posts: 1196 Location: Arizona
|
Code: |
/usr/mqm/bin/strmqm QMGRNAME
/usr/mqm/bin/runmqlsr
/usr/mqm/bin/strmqcsv
|
That should do it. The listener process will have some arguments to specify port, protocol and MQManager name. _________________ Yes, I am an agent of Satan but my duties are largely ceremonial. |
|
Back to top |
|
 |
mq_crazy |
Posted: Thu Nov 11, 2004 12:24 pm Post subject: |
|
|
 Master
Joined: 30 Jun 2004 Posts: 295
|
thanks a lot for your answer, one last question do i need to put /usr/mqm/bin/ for all commands, as in mine they are in /opt/mqm/bin |
|
Back to top |
|
 |
csmith28 |
Posted: Thu Nov 11, 2004 12:31 pm Post subject: |
|
|
 Grand Master
Joined: 15 Jul 2003 Posts: 1196 Location: Arizona
|
no, just use the fully qualified path, in AIX it is /usr, I wasn't sure about HP/UX. _________________ Yes, I am an agent of Satan but my duties are largely ceremonial. |
|
Back to top |
|
 |
mq_crazy |
Posted: Thu Nov 11, 2004 12:41 pm Post subject: |
|
|
 Master
Joined: 30 Jun 2004 Posts: 295
|
Thanks a lot dude for all the help. |
|
Back to top |
|
 |
vennela |
Posted: Thu Nov 11, 2004 12:49 pm Post subject: |
|
|
 Jedi Knight
Joined: 11 Aug 2002 Posts: 4055 Location: Hyderabad, India
|
What you should do is put all things needed for MQ in a script and give the script to your Unix admin.
Quote: |
thanks a lot for your answer, one last question do i need to put /usr/mqm/bin/ for all commands, as in mine they are in /opt/mqm/bin |
Yes
On HP it is /opt/mqm/bin |
|
Back to top |
|
 |
csmith28 |
Posted: Thu Nov 11, 2004 12:52 pm Post subject: |
|
|
 Grand Master
Joined: 15 Jul 2003 Posts: 1196 Location: Arizona
|
Oh, I almost forgot. All of those commands should run as mqm user. _________________ Yes, I am an agent of Satan but my duties are largely ceremonial. |
|
Back to top |
|
 |
EddieA |
Posted: Thu Nov 11, 2004 1:55 pm Post subject: |
|
|
 Jedi
Joined: 28 Jun 2001 Posts: 2453 Location: Los Angeles
|
And remember that runmqlsr actually is the listener process. It doesn't spawn off another process and terminate like the other (str*)commands.
Cheers, _________________ Eddie Atherton
IBM Certified Solution Developer - WebSphere Message Broker V6.1
IBM Certified Solution Developer - WebSphere Message Broker V7.0 |
|
Back to top |
|
 |
fjb_saper |
Posted: Thu Nov 11, 2004 3:24 pm Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
You should in fact create multiple scripts.
The script for sysadmin should just set the user id => mqm
and call up some script that you control.
There you can specify what you need to do by qmgr. This way you can add qmgrs or remove them (comment out a line) etc without having to annoy the sysadmin for each change in your landscape.
ex:
Code: |
# Start MQ listener, queue manager, trigger monitor, command server
export JAVA_COMPILER=NONE
export AMQ_NO_SIGWAIT_SIGTRAP=1
export AMQ_SIGCHLD_SIGACTION=YES
# Set return code
RC=0
# start listener for the qmgr $1 on port $2
/bin/runmqlsr -m $1 -t tcp -p $2 &
RC=`expr ${RC} + $?`
# start qmgr $1
/bin/strmqm $1
RC=`expr ${RC} + $?`
#start trigger mon on INIT_QUEUE for $1
/bin/runmqtrm -m $1 -q INIT_QUEUE &
RC=`expr ${RC} + $?`
# start command server
/bin/strmqcsv $1
RC=`expr ${RC} + $?`
echo "RC $1=${RC}"
exit $RC |
and
Code: |
#!/usr/bin/ksh
# Start MQ listener, queue manager, trigger monitor
# Initialize Return code
RC=0
/var/mqm/bin/startb1MQ.sh QMGR1 port1
RC=`expr ${RC} + $?`
/var/mqm/bin/startb1MQ.sh QMGR2 port2
RC=`expr ${RC} + $?`
/var/mqm/bin/startb1MQ.sh QMGR3 port3
RC=`expr ${RC} + $?`
/var/mqm/bin/startb1MQ.sh QMGR4 port4
RC=`expr ${RC} + $?`
exit $RC |
Enjoy  |
|
Back to top |
|
 |
|