LSF Version 7.3 - Administering Platform LSF

Writing Shell Scripts in lstcsh
744 Administering Platform LSF
connect
Syntax connect [host_name]
Description lstcsh opens a connection to a remote host when the first command is executed
remotely on that host. The same connection is used for all future remote executions
on that host.
The
connect command with no argument displays connections that are currently
open.
The
connect host_name command creates a connection to the named host. By
connecting to a host before any command is run, the response time is reduced for
the first remote command sent to that host.
lstcsh has a limited number of ports available to connect to other hosts. By default
each shell can only connect to 15 other hosts.
Examples connect
CONNECTED WITH SERVER SHELL
hostA +
connect hostB
Connected to hostB
connect
CONNECTED WITH SERVER SHELL
hostA +
hostB -
In this example, the connect command created a connection to host hostB, but the
server shell has not started.
Writing Shell Scripts in lstcsh
You should write shell scripts in /bin/sh and use the lstools commands for load
sharing. However,
lstcsh can be used to write load-sharing shell scripts.
By default, an
lstcsh script is executed as a normal tcsh script with load-sharing
disabled.
Run a script with load sharing enabled
The lstcsh -L option tells lstcsh that a script should be executed with load
sharing enabled, so individual commands in the script may be executed on other
hosts.
There are three different ways to run an
lstcsh script with load sharing enabled:
Run lstcsh -L script_name, or
Make the script executable and put the following as the first line of the script.
By default,
lstcsh is installed in LSF_BINDIR.