|
| This chapter explains how to control TG in the command-line. |
| |
| AUTOEXEC |
| |
Synopsis |
: |
autoexec < on | off > |
| options |
: |
|
| |
|
- |
| |
|
enables or disables a job executed automatically. When this setting is made "OFF", Even if the event set as a trigger occured, JOB is not executed. |
| |
| |
| CHECK |
| |
Synopsis |
: |
check config
check driver [ MySQL | PostgreSQL | ORACLE ]
check isolation
|
| options |
: |
|
| |
|
config |
| |
|
tests agent be able to connect to the target database using a current configration. |
| |
|
|
| |
|
driver [ MySQL | PostgreSQL | ORACLE ] |
| |
|
tests JDBC driver correctly loaded which is specified at "DRIVER_CLASS" parameter. When JDBC driver name is given , specified JDBC driver will be checked. |
| |
|
|
| |
|
isolation |
| |
|
tests transaction isolation level supported by JDBC driver which is specified at "DRIVER_CLASS" parameter. |
| |
|
|
| |
| DELETE |
| |
Synopsis |
: |
delete config < config-name > |
| options |
: |
|
| |
|
config < config-name > |
| |
|
deletes specified configration which is registered in TG. |
| |
| |
| EDIT |
| |
Synopsis |
: |
edit config
edit job <job-number> |
| options |
: |
|
| |
|
config |
| |
|
Open current configration using a editor which is specified by EDITOR system parmeter. |
| |
|
|
| |
|
job <job-number> |
| |
|
Open specified JOB by job-number using a EDITOR which is specified by EDITOR system parmeter. |
| |
| |
| EXECUTE |
| |
Synopsis |
: |
execute job < job-number > |
| options |
: |
|
| |
|
job < job-number > |
| |
|
execute specified JOB by job-number manually. The JOB of which JOB_TYPE is "USER_REQUEST" is never executed as long as this command is not used. |
| |
| |
| EXIT |
| |
Synopsis |
: |
exit |
| options |
: |
|
| |
|
- |
| |
|
Terminates TG. |
| |
| |
| HELP |
| |
Synopsis |
: |
help |
| options |
: |
|
| |
|
- |
| |
|
Access the command-line help system. |
| |
| |
| LIST |
| |
Synopsis |
: |
list config |
| options |
: |
|
| |
|
config |
| |
|
Displays the list of jobs which are registed in TG. |
| |
| |
| MASTERSERVER |
| |
Synopsis |
: |
masterserver < on | off > |
| options |
: |
|
| |
|
- |
| |
|
Change Multi-server mode on / off. When this setting is made "OFF", REMOTE_SERVER parameter is ignored. |
| |
| |
| MONITOR |
| |
Synopsis |
: |
monitor [ detail | summary ] [ < monitoring-time > ] [ wait ]
|
| options |
: |
|
| |
|
- |
| |
|
Monitors agent status until the return key is hit. The meaning of each field is as follows.
| |
Ags |
: |
Displays the command that is issued to agents. Agents try to change them directed status. However, Agents waiting results of the query might take time for a while to change their status.
- DISC(DISCONNECTED)
Agents are disconnecting or disconnected from the target database.
- WAIT(WAITING)
Agents are freezing or trying to stop transactions.
- ACTV(ACTIVE)
Agents are executing or trying to start transactions. |
| |
|
|
|
| |
Act |
: |
Displays the number of active agents. |
| |
|
|
|
| |
SES |
: |
Displays the number of agents that are connected with the target database. |
| |
|
|
|
| |
ErD |
: |
Displays the number of agents that are disconnected from the target database due to the error or trouble of the database. |
|
|
|
| |
ERR |
: |
Displays the number of agents that are failed to execute the query. |
| |
|
|
|
| |
TPS |
: |
Displays the number of transactions that are executed in one second. |
|
| |
|
|
| |
|
[ < monitoring-time > ] |
| |
|
Specifies the monitoring time in seconds. When you want to stop the monitoring, use RESETMONITOR command. |
| |
|
|
| |
|
[ wait ] |
| |
|
The prompt is not returned until the monitoring period ends. This command is used to execute TG from the batch file or the shell script. |
| |
| |
| NORMAL |
| |
Synopsis |
: |
normal |
| options |
: |
|
| |
|
- |
| |
|
Changes agent status from verbose-mode to normal-mode. For details of verbose-mode, see the section of VERBOSE command. |
| |
| |
| RELOAD |
| |
Synopsis |
: |
reload config |
| options |
: |
|
| |
|
config |
| |
|
When configuration file (tg.conf) is changed, the change is reflected in TG. This command cannot be executed while Agent is connecting with the target database. In that case, execute this command again after issuing the DISCONNECT command and breaking the connection. |
| |
| |
| REGIST |
| |
Synopsis |
: |
regist config < config-name > |
| options |
: |
|
| |
|
config < config-name > |
| |
|
Registers a current configration in TG giving a name. The registered configuration can be called by the REPLACE command. |
| |
| |
| RENAME |
| |
Synopsis |
: |
rename config < old config-name > < new config-name > |
| options |
: |
|
| |
|
config < old config-name > < new config-name > |
| |
|
Renames specified configration name. |
| |
| |
| REPLACE |
| |
Synopsis |
: |
replace config < config-name > |
| options |
: |
|
| |
|
config < config-name > |
| |
|
Loads specified configuration which is registered in TG. When this command is issued, current configration is overwrited with the loaded configuration. |
| |
| |
| RESETMONITOR |
| |
Synopsis |
: |
resetmonitor |
| options |
: |
|
| |
|
- |
| |
|
Stops the monitoring forcely which is given a period using MONITOR <monitoring time> command. |
| |
| |
| SET |
| |
Synopsis |
: |
| |
SET JDBC_DRIVER |
|
< MySQL | PostgreSQL | ORACLE > |
| |
SET DRIVER_TYPE |
|
< thin | oci | oci8 > |
| SET DRIVER_CLASS |
|
< JDBC driver class string > |
| SET HOSTNAME |
|
[ target hostname ] |
| SET PORT |
|
[ target listener port number ] |
| SET DATABASE_NAME |
|
< target database name > |
| SET SID_NAME |
|
< target SID name > |
| SET TNSNAMES |
|
< target tnsnames > |
| SET JDBC_URL |
|
< JDBC URL string > |
| SET USERNAME |
|
< username > |
| SET PASSWORD |
|
< password > |
| SET SESSIONS |
|
< 1..2000 > |
| SET THINKTIME |
|
< in milli second > |
| SET EXECUTION_COUNT |
|
< -1 or higher > |
| SET RECONNECT_WAIT |
|
< in milli second > |
| SET DELAY_START |
|
< true or false > |
| SET ERROR_RETRY_COUNT |
|
< -1 or higher > |
| SET ERROR_RETRY_WAIT |
|
< in milli second > |
| SET ERROR_RECONNECT_COUNT |
|
< -1 or higher > |
| SET ERROR_RECONNECT_WAIT |
|
< in milli second > |
| SET AUTO_COMMIT |
|
< true or false > |
| SET ISOLATION_LEVEL |
|
< DEFAULT | READ_UNCOMMITTED | READ_COMMITTED | REPEATABLE_READ | SERIALIZABLE > |
|
| options |
: |
|
| |
|
- |
| |
|
Gives a value to each parameter.
* When TG ends, the value given by the SET command is lost. |
| |
| |
| SHOW |
| |
Synopsis |
: |
show system
show database
show agent
show variables
show transactions
show mtransactions
show jobs
show jobsummary
show status
throughput [ summary | details ]
|
| options |
: |
|
| |
|
- |
| |
|
shows each configuration and status information.
| |
system |
: |
Shows the whole attribution of TG. For example, log filename, editor, etc ... |
| |
|
|
|
| |
database |
: |
Shows the target atabase information. This information is specified at the field of DATABASE in "tg.conf" configuration file. |
| |
|
|
|
| |
agent |
: |
Shows username and password, the number of sessions which are used to connect to the target database by agents. This information is specified at the field of AGENT in "tg.conf" configuration file. |
| |
|
|
| |
variables |
: |
Shows the random variables information registered in TG. This information is specified at the field of VARIABLE in "tg.conf" configration file. |
| |
|
|
| |
transactions |
: |
Shows the transaction information registered in TG. This information is specified at the field of TRANSACTION in "tg.cong" configration file. |
| |
|
|
|
| |
mtransactions |
: |
Shows the modified transaction information (random variables are replaced into "?" which means variable in JDBC API 'prepareStatement'). |
| |
|
|
|
| |
Jobs |
: |
Shows the jobs information registered in TG. This information is specified at the field of JOB in "tg.conf" configration file. |
| |
|
|
| |
jobsummary |
: |
Show the transaction name list which is registered in TG. |
| |
|
|
|
| |
status |
: |
Shows how transactions are executed. When you use MultiServer mode, Slave server's information will be displayed too. |
| |
|
|
|
|
| |
| |
| SLEEP |
| |
Synopsis |
: |
sleep <sleep time > |
| options |
: |
|
| |
|
<sleep time > |
| |
|
specify the sleep time in second. TG doesn't recieve a command during this time.
This command is useful when TG is executed in a batch file or schell script.
* This command is supported by TG ver 0.83 or later. |
| |
| |
| SPOOL |
| |
Synopsis |
: |
spool <spool filename | on | off > |
| options |
: |
|
| |
|
<spool filename > |
| |
|
Stores query results in the specified logfile. |
| |
|
|
| |
|
< on | off > |
| |
|
Stores query results in the "YYYYMMDDHH24MISS.log" logfile. |
| |
| |
| VERBOSE |
| |
Synopsis |
: |
verbose [Agent-ID] |
| options |
: |
|
| |
|
- |
| |
|
Changes agent status into the verbose-mode. Verbose Mode lets you look at the actual agents processing. Executing SQL statements, getting results of the query, etc... However, verbose-mode consumes a lot of CPU time. Please use this mode only for specific. |
| |
|
|
| |
|
[ Agent-ID ] |
| |
|
Changes specified agent into the verbose-mode with Agent-ID. |
| |
| |
| ! |
| |
Synopsis |
: |
!<command> |
| options |
: |
|
| |
|
< command > |
| |
|
Executes external commands or batch files, shell scripts, etc. |
| |
| |
| CONNECT |
| |
Synopsis |
: |
connect [ all ] |
| options |
: |
|
| |
|
- |
| |
|
Generates agents and makes them connect to the target database. The number of agents is specified at SESSIONS parameter in "tg.conf" configration file.。 |
| |
|
|
| |
|
[ All ] |
| |
|
The prompt is not returned until all Agents connect to the target database. This option is used when TG is executed in a batch file or schell script. |
| |
| |
| DISCONNECT |
| |
Synopsis |
: |
connect [ all ] |
| options |
: |
|
| |
|
- |
| |
|
Makes agents disconnect from the target database. |
| |
|
|
| |
|
[ All ] |
| |
|
The prompt is not returned until all Agents disconnect from the target database. This option is used when TG is executed in a batch file or schell script. |
| |
| |
| START |
| |
Synopsis |
: |
start |
| options |
: |
|
| |
|
- |
| |
|
Changes agent status from "WAIT" into "ACTIVE".
*This command can be issued When agent status is "WAIT". |
| |
| |
| STOP |
| |
Synopsis |
: |
stop |
| options |
: |
|
| |
|
- |
| |
|
Changes agent status from "ACTIVE" into "WAIT".
*When this command is issued, the session between Agents and the target database is kept, never cut. |
| |
|