This chapter is aimed at the LSF administrator running a UNIX cluster or a mixed UNIX/NT cluster. If your cluster contains only Windows NT hosts, see Chapter 7, `LSF Database - Windows NT', on page 49.
LSF database administration is the only part of LSF that
requires you to log on using the LSF primary administrator user account. The
LSF primary administrator account will be the first cluster administrator specified
in the lsf.cluster.cluster file. If your cluster
includes any Windows NT hosts, do not attempt to change the LSF primary administrator
after LSF has been installed.
Install LSF Analyzer using lsfsetup, the UNIX installation program for LSF Suite. For detailed instructions, see the LSF Installation Guide.
When you install LSF Analyzer for the first time, you are prompted to specify the LSF database server. This defines the LSF_DB_HOST parameter in the lsf.conf file. The LSF database files will be installed on the machine you specify.
If you specify the installation host (the machine used to run lsfsetup) as the LSF database server, the LSF database installation program starts automatically.
If you specify another machine as the LSF database server, you have to install the LSF database using a separate installation file that is included in the regular LSF distribution. Complete the regular LSF installation, usinglsfsetup,and then log onto the LSF database server and runlsfdbsetup.
When you install the LSF database, you are prompted to specify the LSF database directory. By default, this is /usr/local/lsf_db. All the LSF database files are installed under this directory. The database is created automatically and has the same name as the cluster.
Once the database is installed, you must start it.
To start the LSF database, log onto the LSF database server as the LSF primary administrator and type:
% lsdbserver start
The lsdbserver command is located in the /bin subdirectory of the LSF database directory.
The utilities described in this section help you monitor and limit the size of the LSF database, to get better performance from LSF Analyzer. They are used to:
The lsf.conf file and the online documentation for database utility commands should be accessible to the working environment of the LSF primary administrator on the LSF database server (LSF_ENVDIR must be set). For example:
% setenv PATH $DB/bin:$PATH
% setenv MANPATH $DB/man:$MANPATH
where $DB is the LSF database directory.
To run any of the commands in this section, you must log onto the LSF database server as the LSF primary administrator. The following commands all support the standard -h option.
lsdbserver start|stop
Starts up or shuts down the LSF database.
lsdbcreatedatabase_nameCreates a new database with the LSF database schema. Specify a unique database name (you cannot use the name of an existing LSF database).
lsdbstatus
Prints the current status of the LSF database server (which configuration file is in use; maximum and actual number of connections; details of all connections).
lsdbrecordsdatabase_name[ -ttime]Prints reference numbers for job-related and resource-related records. If-tis specified, prints another pair of reference numbers, for job and resource records logged before the specified time.
If you want good performance from LSF Analyzer, you should keep the LSF database small. When the reference numbers exceed 50,000 for job records or 400,000 for resource records, you should archive the data using the lsdmove command.
The rate of growth of your LSF database depends on all of the following:
-ttimeTo specify time, use the following syntax:
time = [year /]month / day / hour : minute
Use 4 digits for the year, if specified. Use 2 digits for month, day, hour, and minute.
lsdbbuildidxdatabase_nameReindexes the specified LSF database. If LSF Analyzer users have trouble retrieving data from the database, try this command, as there might be a problem with the database index.
lsdbcleardatabase_nameDeletes all the logged data from the data tables in the specified LSF database, leaving an empty LSF database.
You should not run this command on a working database, such as the online LSF database. If you do, use the lsdbstatus command and make sure there are no open connections to the database before using this command. This will prevent data inconsistency problems.
lsdbdropdatabase_nameDrops the specified LSF database (deletes the entire LSF database, including all of the logged data).
lsdbmovesource_database_name destination_database_name
Moves the contents of the source database (data) to the destination database. This command must be followed by thebadmin reconfigcommand.
Data collection can be tuned by modifying the parameters configured in the lsb.params file. For example, edit:
LSB_CONFDIR/cluster/configdir/lsb.params
The following parameters can be configured:
DB_DEFAULT_INTVALSpecifies the time interval to log job data (except load information and resource usage of running and suspended jobs) to the database, in minutes. To stop logging job data, setDB_DEFAULT_INTVAL=-1.
Default: 5
DB_JOB_RES_USAGE_INTVAL
Optional. If defined, specifies the time interval to log resource usage of running and suspended jobs to the database, in minutes.
Default: undefined (job resource is not logged).
DB_LOAD_INTVAL
Specifies the time interval to log load information (internal and external load indices and shared resources), in minutes.
Minimum: 15
Default: 60 (1 hour)
DB_SELECT_LOAD
Optional. Specifies which load information to collect. Possible values are internal load indices, external load indices, and shared resources. This parameter is case sensitive. If more than 4 load values are specified (separated by spaces) only the first 4 will be used. For example,
DB_SELECT_LOAD = ut mem ext_idx1 shared_lic1
will collect CPU utilization, available memory, the user-specified external load indexext_idx1, and the user-specified shared resourceshared_lic1.
Default: ut
The acct2db utility is used to convert job log files (e.g., lsb.acct) into LSF databases, allowing you to analyze LSF data collected before LSF Analyzer was installed. These databases cannot be used as online (active) databases. The license for the acct2db utility expires 30 days after your LSF 3.2 license is generated.
To convert data from an existing job log file, take the following steps:
lsb.acct) is stored.
lsdbcreate command described in the `Command Reference' on page 44.
acct2db command and specify the new database as the target database. Each finished job record in the job log file is converted into a database record.
acct2db [ -h ] [ -V ]
[ -f lsb.acct.file ]
[-H database_host ]
database_name
-h
Prints command usage to stderr and exits.
-V
Prints the LSF release version to stderr and exits.
-flsb.acct.file
Specifies the job log file on the local host which is to be converted into a database.
Default:LSB_SHAREDIR/cluster/logdir/lsb.acct
-Hdatabase_host
Specifies the remote host where the target database is located.
Default: the local host
database_name
Specifies the name of the target LSF database. The target database cannot be the online (active) database.