/
Using Docker to Instantiate PBS

Using Docker to Instantiate PBS

Install Docker

First, make sure you have docker installed. Please see https://docs.docker.com/engine/installation/ for instructions on installing docker on your system. Please don't forget to start docker after the installation.

Launch a PBS Pro container

Open up a terminal and run:

docker run -it --name pbs -h pbs -e PBS_START_MOM=1 pbspro/pbspro bash

This tells docker to launch a PBS Pro container with an interactive shell and name it pbs. Docker will download the PBS Pro docker image from Docker Hub if the image is not already on your system.

By default PBS Pro init script does not start the mom deamon. Therefore we use the -e option to override the value for PBS_START_MOM environment variable. You can use -e to passing additional environment variables if you need to. 

You should now see a terminal window that looks like:

pbsuser@pbs ~

Note that you are logged into a default non-root user account. Before we can submit and run jobs, we need to add some configurations using root account. Exit the current shell and you should return to a root shell. Run: 

qmgr -c "create node pbs"
qmgr -c "set  node pbs queue=workq"

to create a node named pbs and add a queue to it. Then switch back to the default user account and move to its home directory:

su pbsuser
cd

Submit a job

You should now be able to submit and view jobs.

qsub -- /bin/sleep 10
qstat

Feel free to try other PBS Pro commands and have fun.

Related content

Building and Packaging PBS on Debian/Ubuntu
Building and Packaging PBS on Debian/Ubuntu
Read with this
Installing PBS on Linux
Installing PBS on Linux
More like this
Pre-built Packages and Tested Platforms
Pre-built Packages and Tested Platforms
Read with this
PP-660: Add support to PBS init script to act on any PBS daemon individually
PP-660: Add support to PBS init script to act on any PBS daemon individually
More like this
Building OpenPBS Using rpmbuild
Building OpenPBS Using rpmbuild
Read with this
PP-337: Multiple schedulers servicing the PBS cluster
PP-337: Multiple schedulers servicing the PBS cluster
More like this