$ sudoedit /etc/hosts
$ tar axvf torque-6.0.1-1456945733_daea91b.tar.gz
$ sudo apt-get install libssl-dev libboost-dev
$ cd torque-6.0.1-1456945733_daea91b $ ./configure --prefix=/usr/local --with-default-server=hoge
–prefix
: インストール先 (今回は /usr/local 以下に bin や lib が展開するようにした)–with-default-server
: サーバ名 (apt-get でインストールした際の /var/spool/torque/server_name の設定が不要になる)$ make
-j
オプションを付けてスレッド数を指定すると速くコンパイルできる$ sudo make install
sudo make install
するだけで良い。pbs 15001/tcp pbs_mom 15002/tcp pbs_resmom 15003/tcp pbs_resmom 15003/udp pbs_sched 15004/tcp
export LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH
$ sudoedit /etc/ld.so.conf.d/torque.conf
/usr/local/lib
sudo ldconfig
$ source ~/.bashrc
$ source ~/.zshrc
#! /bin/sh ### BEGIN INIT INFO # Provides: torque-server # Required-Start: $remote_fs $local_fs $named $network $time # Required-Stop: $remote_fs $local_fs $named $network # Default-Start: 2 3 4 5 # Default-Stop: 0 1 6 # Short-Description: Start and stop the PBS server # Description: PBS is a versatile batch system for SMPs and clusters. # This script controls the server process. ### END INIT INFO PATH=/usr/sbin:/usr/bin:/sbin:/bin DAEMON=/usr/sbin/pbs_server NAME=torque-server DESC="Torque batch queue server" PIDFILE=/var/spool/torque/server_priv/server.lock test -x $DAEMON || exit 0 # Include torque defaults if available if [ -f /etc/default/torque-server ]; then . /etc/default/torque-server elif [ -f /etc/default/torque ]; then . /etc/default/torque fi # Load lsb functions . /lib/lsb/init-functions case "$1" in start) log_daemon_msg "Starting $DESC" if [ ! -r /var/spool/torque/server_priv/serverdb ]; then DAEMON_SERVER_OPTS="-t create $DAEMON_SERVER_OPTS" fi log_progress_msg "$NAME" start-stop-daemon --start --quiet --pidfile $PIDFILE \ --exec $DAEMON -- $DAEMON_SERVER_OPTS log_end_msg $? ;; stop) log_daemon_msg "Stopping $DESC" "$NAME" start-stop-daemon --stop --quiet --pidfile $PIDFILE \ --exec $DAEMON log_end_msg $? ;; reload|force-reload) log_daemon_msg "Reloading $DESC configuration files" "$NAME" start-stop-daemon --stop --signal 1 --quiet \ --pidfile $PIDFILE --exec $DAEMON log_end_msg $? ;; restart) $0 stop && sleep 2 && $0 start ;; *) N=/etc/init.d/`basename $0` echo "Usage: $N {start|stop|restart|reload|force-reload}" >&2 exit 1 ;; esac exit 0
#! /bin/sh ### BEGIN INIT INFO # Provides: torque-mom # Required-Start: $remote_fs $local_fs $named $network # Required-Stop: $remote_fs $local_fs $named $network # Default-Start: 2 3 4 5 # Default-Stop: 0 1 6 # Short-Description: Start and stop the PBS Mom # Description: PBS is a versatile batch system for SMPs and clusters. # This script controls the mom process. ### END INIT INFO PATH=/usr/sbin:/usr/bin:/sbin:/bin DAEMON=/usr/sbin/pbs_mom NAME=torque-mom DESC="Torque Mom" PIDFILE=/var/spool/torque/mom_priv/mom.lock test -x $DAEMON || exit 0 # Include defaults if available if [ -f /etc/default/$NAME ] ; then . /etc/default/$NAME fi # Load lsb functions . /lib/lsb/init-functions case "$1" in start) log_daemon_msg "Starting $DESC" "$NAME" start-stop-daemon --start --quiet --pidfile $PIDFILE \ --exec $DAEMON -- $DAEMON_OPTS log_end_msg $? ;; stop) log_daemon_msg "Stopping $DESC" "$NAME" start-stop-daemon --stop --quiet --pidfile $PIDFILE \ --exec $DAEMON log_end_msg $? ;; reload|force-reload) log_daemon_msg "Reoading $DESC configuration files" "$NAME" start-stop-daemon --stop --signal 1 --quiet --pidfile $PIDFILE \ --exec $DAEMON log_end_msg $? ;; restart) log_daemon_msg "Restarting $DESC" "$NAME" start-stop-daemon --stop --quiet --pidfile $PIDFILE \ --exec $DAEMON sleep 1 start-stop-daemon --start --quiet --pidfile $PIDFILE \ --exec $DAEMON -- $DAEMON_OPTS log_end_msg $? ;; *) N=/etc/init.d/$NAME log_action_msg "Usage: /etc/init.d/torque-mom {start|stop|restart|reload|force-reload}" exit 2 ;; esac exit 0
#! /bin/sh ### BEGIN INIT INFO # Provides: torque-scheduler # Required-Start: $all # Required-Stop: $all # Should-Start: $all # Should-Stop: $all # Default-Start: 2 3 4 5 # Default-Stop: 0 1 6 # Short-Description: Start and stop the Torque scheduler # Description: PBS is a versatile batch system for SMPs and clusters. # This script controls the scheduler. ### END INIT INFO PATH=/sbin:/bin:/usr/sbin:/usr/bin DAEMON=/usr/sbin/pbs_sched NAME=torque-scheduler DESC="Torque scheduler" PIDFILE=/var/spool/torque/sched_priv/sched.lock test -x $DAEMON || exit 0 # Include defaults if available if [ -f /etc/default/$NAME ] ; then . /etc/default/$NAME elif [ -f /etc/default/torque ]; then . /etc/default/torque fi # set -e cannot work, otherwise the log_end_msg will not be shown # set -e # Load lsb functions . /lib/lsb/init-functions case "$1" in start) log_begin_msg "Starting $DESC: " start-stop-daemon --start --quiet \ --pidfile $PIDFILE \ --exec $DAEMON -- $DAEMON_OPTS log_end_msg $? ;; stop) log_begin_msg "Stopping $DESC: " start-stop-daemon --stop --quiet \ --pidfile $PIDFILE \ --exec $DAEMON log_end_msg $? ;; reload) # send a SIGHUP to force scheduler to reload config file log_begin_msg "Reloading $DESC configuration files" start-stop-daemon --stop --signal 1 --quiet \ --pidfile $PIDFILE \ --exec $DAEMON log_end_msg $? ;; force-reload) # check whether $DAEMON is running. If so, restart start-stop-daemon --stop --test --quiet \ --pidfile $PIDFILE \ --exec $DAEMON \ && $0 restart \ || exit 0 ;; restart) log_begin_msg "Restarting $DESC: " start-stop-daemon --stop --quiet \ --pidfile $PIDFILE \ --exec $DAEMON sleep 1 start-stop-daemon --start --quiet \ --pidfile $PIDFILE \ --exec $DAEMON -- $DAEMON_OPTS log_end_msg $? ;; *) N=/etc/init.d/`basename $0` log_success_msg "Usage: $N {start|stop|restart|force-reload}" exit 1 ;; esac exit 0
$ sudo apt-get install sysv-rc-conf $ cd /etc/init.d $ sudo sysv-rc-conf 起動させたいスクリプト on
$ chmod +x linux_amd64_352_79_release.run $ sudo ./linux_amd64_352_79_release.run
$ cd torque-6.0.1-1456945733_daea91b $ make distclean
$ ./configure --prefix=/usr/local --with-default-server=hoge --enable-nvidia-gpus --with-nvml-include=/usr/include/nvidia/gdk --with-nvml-lib=/usr/lib/x86_64-linux-gnu --with-hwloc-path=/usr/include
–prefix
: インストール先 (今回は /usr/local 以下に bin や lib が展開するようにした)–with-default-server
: サーバ名 (apt-get でインストールした際の /var/spool/torque/server_name の設定が不要になる)–enable-nvidia-gpus
: torque-mom で GPU を使うノード–with-nvml-include
: nvml のインクルードファイルのあるディレクトリのパス–with-nvml-lib
: nvml のライブラリファイルのあるディレクトリのパス–with-hwloc-path
: hwloc のあるディレクトリのパス