| | 4 | |
| | 5 | |
| | 6 | == Set up torque/PBS == |
| | 7 | |
| | 8 | '''This section describes how to set up torque PBS. If it's already set up, skip this section. |
| | 9 | ''' |
| | 10 | First, we install the torque PSB system: |
| | 11 | |
| | 12 | |
| | 13 | {{{ |
| | 14 | apt-get install torque-server torque-scheduler torque-mom torque-client |
| | 15 | }}} |
| | 16 | |
| | 17 | Then stop all the running torque processes: |
| | 18 | |
| | 19 | |
| | 20 | {{{ |
| | 21 | /etc/init.d/torque-mom stop |
| | 22 | /etc/init.d/torque-scheduler stop |
| | 23 | /etc/init.d/torque-server stop |
| | 24 | }}} |
| | 25 | |
| | 26 | Create the PBS server (say "yes" when prompted): |
| | 27 | |
| | 28 | |
| | 29 | {{{ |
| | 30 | pbs_server -t create |
| | 31 | }}} |
| | 32 | |
| | 33 | Then kill the PBS server process: |
| | 34 | |
| | 35 | {{{ |
| | 36 | killall pbs_server |
| | 37 | }}} |
| | 38 | |
| | 39 | Set up the PBS server: |
| | 40 | |
| | 41 | |
| | 42 | {{{ |
| | 43 | echo $(hostname -f) > /etc/torque/server_name |
| | 44 | echo $(hostname -f) > /var/spool/torque/server_priv/acl_svr/acl_hosts |
| | 45 | echo $(hostname -f) > /var/spool/torque/mom_priv/config |
| | 46 | |
| | 47 | echo root@$(hostname -f) > /var/spool/torque/server_priv/acl_svr/operators |
| | 48 | echo root@$(hostname -f) > /var/spool/torque/server_priv/acl_svr/managers |
| | 49 | |
| | 50 | echo "$(hostname -f) np=4" > /var/spool/torque/server_priv/nodes |
| | 51 | }}} |
| | 52 | |
| | 53 | If you have a line in your /etc/hosts file that resolves your hostname to 127.0.1.1, you have to comment it out, e.g. |
| | 54 | |
| | 55 | |
| | 56 | {{{ |
| | 57 | #127.0.1.1 console.grid.orbit-lab.org console |
| | 58 | }}} |
| | 59 | |
| | 60 | Once you've done that, start everything back up again: |
| | 61 | |
| | 62 | |
| | 63 | {{{ |
| | 64 | /etc/init.d/torque-server start |
| | 65 | /etc/init.d/torque-scheduler start |
| | 66 | /etc/init.d/torque-mom start |
| | 67 | }}} |
| | 68 | |
| | 69 | Now we'll set up some configuration values: |
| | 70 | |
| | 71 | |
| | 72 | {{{ |
| | 73 | qmgr -c "set server scheduling = True" |
| | 74 | qmgr -c "set server acl_host_enable = True" |
| | 75 | qmgr -c "set server acl_hosts = $(hostname -f)" |
| | 76 | qmgr -c "set server allow_node_submit = True" |
| | 77 | }}} |
| | 78 | |
| | 79 | You'll have to run the commands above as root, since you've set up the root user as the only PBS operator and manager. |