Skip to content
Snippets Groups Projects
Commit 6e39c682 authored by Alexander van Amesfoort's avatar Alexander van Amesfoort
Browse files

Task #9893: merge r37572 from trunk to remove MessageRouter rule part...

Task #9893: merge r37572 from trunk to remove MessageRouter rule part cobalt.task.specification.system. Also remove obsolete build_queues.sh.
parents 987922ef 35dd1139
No related branches found
No related tags found
No related merge requests found
......@@ -2008,7 +2008,6 @@ LCS/MessageBus/qpid/local/bin/sendmsg -text
LCS/MessageBus/qpid/local/bin/start-qpid -text
LCS/MessageBus/qpid/local/bin/stop-qpid -text
LCS/MessageBus/qpid/local/sbin/build_qpid -text
LCS/MessageBus/qpid/local/sbin/build_queues.sh -text svneol=unset#text/x-shellscript
LCS/MessageBus/qpid/local/sbin/qpidd_init.d_script_rhel -text svneol=unset#text/x-shellscript
LCS/MessageBus/qpid/local/sbin/qpidd_init.d_script_sles -text svneol=unset#text/x-shellscript
LCS/MessageBus/qpid/local/sbin/qpidd_init.d_script_ubuntu -text
......
#!/bin/bash
#
# This script will set up the queues and routes needed for the LOFAR
# Production system
# Run it as lofarsys on ccu001 or ccu099
# Depending on the system, it will set up the queues for prod or test
#
# Run this on CCU001, CCU002, or CCU099
host=`hostname -s | tr [a-z] [A-Z]`
hosttype=`hostname -s | tr [a-z] [A-Z] | awk '{print substr($1,0,3)}'`
if [[ "$hosttype" != "CCU" || "$hosttype" != "MCU" ]]; then
echo "Run $0 on a CCU or MCU system"
exit
fi
if [ "$host" == "CCU001" ]; then
# Host definitions: PRODUCTION
ccu="CCU001.control.lofar"
mcu="MCU001.control.lofar"
sas="SAS001.control.lofar"
cobalt_root="cbm001"
cobalt_start=1
cobalt_end=8
mom="LCS023.control.lofar"
head="lhn001.cep2.lofar"
node_start=1
node_end=94
drg_head="dragnet.control.lofar"
drg_node_start=1
drg_node_end=23
elif [ "$host" == "CCU002" ]; then
# Host definitions: PRODUCTION READY TEST
ccu="ccu002.control.lofar"
mcu="mcu002.control.lofar"
sas="SAS099.control.lofar"
cobalt_root="cbm001"
cobalt_start=9
cobalt_end=9
mom="LCS028.control.lofar"
head="locus102.cep2.lofar"
node_start=98
node_end=99
drg_head="dragproc.control.lofar"
drg_node_start=21
drg_node_end=23
else
# Host definitions: TEST
ccu="CCU099.control.lofar"
mcu="mcu099" # see /etc/hosts
sas="sas099" # see /etc/hosts
cobalt_root="cbm009"
cobalt_start=9
cobalt_end=9
mom="LCS028.control.lofar"
head="locus102.cep2.lofar"
node_start=98
node_end=99
drg_head="dragproc.control.lofar"
drg_node_start=1 # start=1,end=0 allows no drg nodes ...
drg_node_end=0 # ... and thus only the dragproc node
fi
if [ "$1" == "-h" ] || [ "$1" == "-?" ] || [ "$1" == "--help" ]; then
echo "usage: $0 [-h|-?|--help|--flush]"
echo " -h , -? , --help produces this message"
echo " --flush will flush the routing tables of the federated brokers in the TEST environment before setup."
exit
else
if [ "$1" == "--flush" ]; then
# flush all routing
for name in $sas $ccu $mcu $mom $head
do
echo flushing routing tables of broker at $name
echo qpid-route route flush $name
qpid-route route flush $name
done
for i in $(seq $cobalt_start $cobalt_end)
do
name=$cobalt_root$i".control.lofar"
echo flushing routing tables of broker at $name
echo qpid-route route flush $name
qpid-route route flush $name
done
for name in $(seq -f "locus%03g.cep2.lofar" $node_start $node_end)
do
echo flushing routing tables of broker at $name
echo qpid-route route flush $name
qpid-route route flush $name
done
exit
fi
fi
# Start setup
qpid-config -b $ccu add exchange topic mac.task.feedback.state
# forcefed will force-delete the queues, create them and setup the
# federation
for i in $(seq $cobalt_start $cobalt_end)
do
name=$cobalt_root$i".control.lofar"
fed lofar.task.feedback.processing $name $ccu
fed lofar.task.feedback.dataproducts $name $ccu
fed lofar.task.feedback.state $name $ccu
done
fed lofar.task.feedback.processing $head $ccu
fed lofar.task.feedback.dataproducts $head $ccu
fed lofar.task.feedback.state $head $ccu
fed lofar.task.feedback.processing $drg_head $ccu
fed lofar.task.feedback.dataproducts $drg_head $ccu
fed lofar.task.feedback.state $drg_head $ccu
fed otdb.task.feedback.processing $ccu $mcu
fed otdb.task.feedback.dataproducts $ccu $mcu
fed lofar.task.specification.system $mcu $ccu
fed mom.task.feedback.processing $ccu $mom
fed mom.task.feedback.dataproducts $ccu $mom
fed mom.task.feedback.state $ccu $mom
fed mom.task.specification.system $ccu $mom
fed mom.command $sas $mom
fed mom.importxml $sas $mom
fed mom-otdb-adapter.importxml $mom $sas
for NODE in $(seq -f "locus%03g.cep2.lofar" $node_start $node_end)
do
fed lofar.task.feedback.dataproducts $NODE $head
fed lofar.task.feedback.processing $NODE $head
fed lofar.task.feedback.state $NODE $head
done
for NODE in $(seq -f "drg%02g.control.lofar" $drg_node_start $drg_node_end) dragproc.control.lofar
do
fed lofar.task.feedback.dataproducts $NODE $head
fed lofar.task.feedback.processing $NODE $head
fed lofar.task.feedback.state $NODE $head
done
......@@ -12,4 +12,4 @@
lofar.task.feedback.dataproducts: otdb.task.feedback.dataproducts
lofar.task.feedback.processing: mom.task.feedback.processing, otdb.task.feedback.processing
lofar.task.feedback.state: mac.task.feedback.state
lofar.task.specification.system: mom.task.specification.system, cobalt.task.specification.system
lofar.task.specification.system: mom.task.specification.system
......@@ -12,4 +12,4 @@
lofar.task.feedback.dataproducts: otdb.task.feedback.dataproducts
lofar.task.feedback.processing: mom.task.feedback.processing, otdb.task.feedback.processing
lofar.task.feedback.state: mac.task.feedback.state
lofar.task.specification.system: mom.task.specification.system, cobalt.task.specification.system
lofar.task.specification.system: mom.task.specification.system
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment