Execute a Command or Script on Grid Installations (installationExec)
The installationExec
command runs a command (such as a system command or TimesTen command) or a script on installations in the grid, as specified.
ttGridAdmin installationExec [-only hostname[.installname]] [-exclude hostname[.installname]] [-parallel n] command | -script filepath
As the command or script runs, the TIMESTEN_INSTALL
environment variable is set to contain the fully qualified path name of the installation as defined in the model.
Options
The installationExec
command has the options:
Option | Description |
---|---|
|
The command or script is run only on the specified installations. Specify just one installation with Use host names and installation names as defined in the model. You do not have to include the installation name if it is the only installation on the host. |
|
The command or script is run on all installations in the grid except for those specified. Specify just one installation with Use host names and installation names as defined in the model. You do not have to include the installation name if it is the only installation on the host. |
|
Specifies that the command or script runs on no more than |
|
Or:
|
Examples
This example checks the disk space usage on the file system of each installation.
% ttGridAdmin installationExec df '$TIMESTEN_INSTALL' Commands executed on: mysys2host.installation1 rc 0 mysys4host.installadc rc 0 mysys1host.installation1 rc 0 mysys3host.installslc rc 0 Return code from mysys2host.installation1: 0 Output from mysys2host.installation1: Filesystem 1K-blocks Used Available Use% Mounted on /dev/xvda2 117144964 42660228 68534120 39% / Return code from mysys4host.installadc: 0 Output from mysys4host.installadc: Filesystem 1K-blocks Used Available Use% Mounted on /dev/xvda2 117144964 42660228 68534120 39% / Return code from mysys1host1.installation1: 0 Output from mysys1host.installation1: Filesystem 1K-blocks Used Available Use% Mounted on /dev/xvda2 173483816 57971304 106700020 36% / Return code from mysys3host.installslc: 0 Output from mysys3host.installslc: Filesystem 1K-blocks Used Available Use% Mounted on /dev/xvda2 173483816 57971312 106700012 36% /
Notes
-
The command or script is run as the instance administrator on each installation, through passwordless SSH.
-
The command returns 2000 if execution did not complete prior to the timeout.
-
During execution,
stdout
andstderr
output is displayed as part of thestdout
andstderr
output from theinstallationExec
command. Because output is buffered, the output from different commands is not intermingled.