pbs_sched_cc.8B

Langue: en

Version: 328101 (ubuntu - 08/07/09)

Section: 8 (Commandes administrateur)

NAME

pbs_sched_cc - pbs C scheduler

SYNOPSIS

pbs_sched [-a alarm] [-d home] [-L logfile] [-p file] [-S port] [-R port] [-c file]

DESCRIPTION

The pbs_sched program runs in conjunction with the PBS server. It queries the server about the state of PBS and communicates with pbs_resmon to get information about the status of running jobs, memory available etc. It then makes decisions as to what jobs to run.

pbs_sched must be executed with root permission.

OPTIONS

-a alarm
This specifies the time in seconds to wait for a schedule run to finish. If a script takes too long to finish, an alarm signal is sent, and the scheduler is restarted. If a core file does not exist in the current directory, abort() is called and a core file is generated. The default for alarm is 180 seconds.
-d home
This specifies the PBS home directory, PBS_HOME. The current working directory of the scheduler is PBS_HOME/sched_priv. If this option is not given, PBS_HOME defaults to $PBS_SERVER_HOME as defined during the PBS build procedure.
-L logfile
Specifies an absolute path name of the file to use as the log file. If not specified, the scheduler will open a file named for the current date in the PBS_HOME/sched_logs directory (see the -d option).
-p file
This specifies the "print" file. Any output from the C code which is written to standard out or standard error will be written to this file. If this option is not given, the file used will be PBS_HOME/sched_priv/sched_out . See the option.
-S port
This specifies the port to use. If this option is not given, the default port for the PBS scheduler is used.
-R port
This specifies the resource monitor port to use. If this option is not given, the default port for the PBS mom is used. NOTE: this option only makes the mom port available to the scheduler writer. It doesn't force them to use it.
-c file
Specify a configuration file, see description below. If this is a relative file name it will be relative to PBS_HOME/sched_priv, see the -d option. If the -c option is not supplied, pbs_sched will not attempt to open a configuration file.

The options that specify file names may be absolute or relative. If they are relative, their root directory will be PBS_HOME/sched_priv.

 

USAGE

This version of the scheduler requires knowledge of the C language and the PBS API. Source code is provided for a main program for the scheduler. The site must supply the heart of the program. When invoked, the main program performs general initialization and housekeeping chores. Then a locally supplied function, schedinit() is called to perform site specific initialization.

In the main loop, a locally supplied function, schedule() is called to make the scheduling decisions and perform any required actions. Information about jobs and queues is obtained from the Server through the standard PBS API as found in libifl.a. Information about the execution host(s) is obtained from the Resource Monitor. Routines to communicate with the Resource Monitor are found in libnet.a.

If the processing takes more than the allotted time, the scheduler will restart itself. The default amount of time is three minutes. This can be changed with the -a option.

On receipt of a SIGHUP signal, the scheduler will close and reopen its log file and reread its configuration file (if any).

CONFIGURATION FILE

A configuration file may be specified with the -c option. This file may be used to specify the hosts (servers) which are allowed to connect to pbs_sched. The hosts are specified in the configuration file in a manor identical to that used in pbs_mom.
clienthost
One or more servers, one per line, may be specified:
+.IP restricted Allows connections from non-priviledged ports on the named hosts. Typically only used with Mac OSX:
Two host names are always allowed to connection to pbs_sched, "localhost" and the name returned to pbs_sched by the system call gethostname(). These names need not be specified in the configuration file.

The configuration file must be "secure". It must be owned by a user id and group id less than 10 and not be world writable.

 

FILES

$PBS_SERVER_HOME/sched_priv
the default directory for configuration files, typically (/usr/spool/pbs)/sched_priv.

Signal Handling

A C based scheduler will handle the following signals:
SIGHUP
The server will close and reopen its log file and reread the config file if one exists.
SIGALRM
If the site supplied scheduling module exceeds the time limit, the Alarm will cause the scheduler to attempt to core dump and restart itself.
SIGINT and SIGTERM
Will result in an orderly shutdown of the scheduler.

All other signals have the default action installed.

EXIT STATUS

Upon normal termination, an exit status of zero is returned.

SEE ALSO

pbs_sched_tcl(8B), pbs_server(8B), and pbs_mom(8B).
PBS Internal Design Specification