qsub: Once a PBS job script is created, it is submitted to PBS via the qsub command. In its simplest form, qsub takes a single parameter, the name of the script file that you wish to submit.
qstat: The qstat command will allow you to view the contents of the PBS queue.
node1:~/test> qstat Job id Name User Time Use S Queue ---------------- ---------------- ---------------- -------- - ----- 147.node1 testjob psmith 0 R default
qdel: The qdel command takes a single argument, a job number. You can use qdel to abort execution of your job: qdel 147 would cancel execution of the job shown in the qstat example above.
qalter: The qalter command is helpful for altering the parameters of a job after it's submitted. qalter takes two arguments: the PBS directive that you wish to change (like -l), and the job number that you want to change. For example, if you forgot to set the walltime that your job requires, you can change it after it's been submitted:
node1:~> qalter -l walltime=4:00:00 147
pbsnodes: The pbsnodes command, while a useful PBS administration command, can also be informative to the PBS user. pbsnodes -a will list all PBS nodes, their attributes, and job status. This is a useful way to get a list of valid machine properties for use in a #PBS -l directive.
node1:~> pbsnodes -a
node2
state = free
np = 2
properties = gigabit,pcn,m2048,dual,p1800,athlon
ntype = cluster
qpeek: The qpeek command can show you any output your running PBS job is generating without having to wait for completion and PBS to deliver the standard output and standard error. The only argument to the program is the PBS jobid that. Have your program printf/echo/etc. any output that you might be interested in monitoring.
node1:~> qpeek 29038 This is a debug message, out of /tmp space. Input data for event 293482 is bad, discarding.
showscipt: showscript will return the contents of the PBS script that you have submitted. The only argument is the job's PBS jobid.
checkjob: checkjob will give detailed information about your job. This is very useful if your job is remaining in the queued state, and you'd like to see why PBS hasn't executed it:
checking job 157142 (RM job '157142.amdahl.physics.purdue.edu') State: Idle EState: Deferred Creds: user:psmith group:phys class:astro qos:DEFAULT WallTime: 00:00:00 of 00:01:00 SubmitTime: Tue Feb 22 09:49:58 (Time Queued Total: 00:02:54 Eligible: 00:00:01) Total Tasks: 1 Req[0] TaskCount: 1 Partition: ALL Network: [NONE] Memory >= 0 Disk >= 0 Swap >= 0 Opsys: [NONE] Arch: [NONE] Features: [xeon][opteron] Exec: '' ExecSize: 0 ImageSize: 0 Dedicated Resources Per Task: PROCS: 1 NodeAccess: SHARED NodeCount: 1 IWD: [NONE] Executable: [NONE] Bypass: 0 StartCount: 0 PartitionMask: [ALL] job is deferred. Reason: NoResources (cannot create reservation) Holds: Defer (hold reason: NoResources) PE: 1.00 StartPriority: 508 cannot select job 157142 for partition DEFAULT (job hold active)
This particular job getting NoResources because it's requested nodes that are opterons and xeons, which are mutually exclusive.
Preston M Smith 2005-02-22