| 80 | |
| 81 | |
| 82 | == Set up queues == |
| 83 | |
| 84 | Next we'll set up queues: one for each node. |
| 85 | |
| 86 | ''For various reasons, we've decided to make a queue per node and have the console be the single "compute" node, instead of having the nodes be the "compute" nodes. (Mainly because then we can still use legacy disk images, and don't have to worry about configuring the nodes to work with torque.) It might seem "neater" to use "nodes" instead of queues, because this would make it simpler to run an experiment with multiple nodes. In practice, though, it would still be annoying to run an experiment with multiple nodes because you generally care which nodes in this scenario (e.g. you want nodes that are close.) |
| 87 | '' |
| 88 | |
| 89 | First we get a list of nodes, then we'll set up a queue for each one: |
| 90 | |
| 91 | {{{ |
| 92 | list=$(omf stat -t system:topo:all | grep "Node:" | awk -F" " '{print $2}' | cut -f1 -d$'.') |
| 93 | |
| 94 | for l in $list |
| 95 | do |
| 96 | qmgr -c "create queue $l" |
| 97 | qmgr -c "set queue $l queue_type = Execution" |
| 98 | qmgr -c "set queue $l max_running = 1" |
| 99 | qmgr -c "set queue $l enabled = True" |
| 100 | qmgr -c "set queue $l started = True" |
| 101 | done |
| 102 | }}} |
| 103 | |
| 104 | (Again, this must be done as root or as a queue manager.) |
| 105 | |
| 106 | Now we'll disable all the queues, because we are going to re-enable them selectively. |
| 107 | |
| 108 | {{{ |
| 109 | list=$(omf stat -t system:topo:all | grep "Node:" | awk -F" " '{print $2}' | cut -f1 -d$'.') |
| 110 | |
| 111 | for l in $list |
| 112 | do |
| 113 | qmgr -c "set queue $l enabled = False" |
| 114 | done |
| 115 | }}} |
| 116 | |
| 117 | |
| 118 | Check with |
| 119 | |
| 120 | |
| 121 | {{{ |
| 122 | qstat -Q |
| 123 | }}} |