Hildo Biersma > DB2-Admin-3.1 > db2_trace_connection

Download:
DB2-Admin-3.1.tar.gz

Annotate this POD

CPAN RT

New  1
Open  0
View/Report Bugs
Source  

NAME ^

db2_trace_connection - Trace a DB2 connection

SYNOPSIS ^

  db2_trace_connection -dbname <database>
                     [ -user <userid> ]
                     [ -agent <agent id> ]
                     [ -time <wait time> ]
                     [ -repeat ]

EXAMPLE ^

  db2_trace_connection -dbname FOOBAR
  db2_trace_connection -dbname FOOBAR -user myuserid
  db2_trace_connection -dbname FOOBAR -agent 789

DESCRIPTION ^

The db2_trace_connection script is used to trace a DB2 connection. It runs two application snapshots in close succession, then shows application activity in between the snapshots.

When invoked with only a -dbname parameter, it displays a list of users connected to the database. When the -user parameter is added, it displays a list of database connections for that userid. The application snapshot is only collected when the -agent parameter is specified.

OPTIONS ^

-dbname <database>

This mandatory option specifies the database name. This must be a database name or alias defined in the local database directory.

If no other options are specified, the script will display a list of connected users.

-user <userid>

This option specifies a userid for which connections should be listed. It is ignored in the presence of the -agent option. When -user is specified, the script will display a list of active connections for the application.

-agent <agent id>

This option specifies the agent id to be traced.

-time <delay>

This option specifies the delay between snapshots in seconds. The default is 5 seconds.

-repeat

This option causes db2_trace_connection to keep getting snapshots every few seconds and to display the incremental changes.

BUGS ^

As it stands, this script only runs locally, i.e. on the database server. If you have SYSMON privilege and can map from database alias to instance name (based on the node directory), you can make it work remotely as well.

AUTHOR ^

  Hildo Biersma

SEE ALSO ^

  DB2::Admin(3)
syntax highlighting: