pbs_track -j <JOBID> [-b] <executable> [args]
The pbs_track command tells a pbs_mom daemon to monitor the lifecycle and resource usage of the process that it launches using exec(). The pbs_mom is told about this new process via the Task Manager API, using tm_adopt(). The process must also be associated with a job that already exists on the pbs_mom.
By default, pbs_track will send its PID to TORQUE via tm_adopt(). It will then perform an exec(), causing <executable> to run with the supplied arguments. pbs_track will not return until the launched process has completed because it becomes the launched process.
This command can be considered related to the pbsdsh command which uses the tm_spawn() API call. The pbsdsh command asks a pbs_mom to launch and track a new process on behalf of a job. When it is not desirable or possible for the pbs_mom to spawn processes for a job, pbs_track can be used to allow an external entity to launch a process and include it as part of a job.
This command improves integration with TORQUE and SGI's MPT MPI implementation.
The pbs_track command accepts a path to a program/executable (<executable>) and, optionally, one or more arguments to pass to that program.
Because the pbs_track command becomes a new process (if used without -b), its exit status will match that of the new process. If the -b option is used, the exit status will be zero if no errors occurred before launching the new process.
If pbs_track fails, whether due to a bad argument or other error, the exit status will be set to a non-zero value.