9.5.4. tpm diag Command

The tpm diag command will create a TGZ file including log files, current dataservice status and a number of OS metrics.

shell> tpm diag
NOTE  >> host1 >> Diagnostic information written to /home/tungsten/tungsten-diag-2013-10-09-21-04-23.tgz

The operation of tpm diag differs between installation types (Staging vs INI). This is outlined below:

  • With Staging-method deployments, the tpm diag command can be issued in two ways:

    • The tpm diag command alone will obtain diagnostics from all hosts in the cluster.

    • The tpm diag --hosts host1,host2,hostN command will obtain diagnostics from the specified host(s) only.

  • Within an INI installation, the behaviour will depend on a number of factors, these are outlined below

    • For versions prior to 5.3.7, and version 6.0.0 to 6.0.4

      • The tpm diag command alone will attempt to obtain diagnostics from all hosts in the cluster if ssh has been configured and the other hosts can be reached.

    • For versions 5.3.7 to 5.4.0, and versions 6.0.5 onwards

      • The tpm diag command alone will ONLY obtain diagnostics from the local host on which the command is executed.

      • The tpm diag --hosts host1,host2,hostN command will obtain diagnostics from the specified host(s) only.

      • The tpm diag -a|--allhosts command will attempt to obtain diagnostics from all hosts in the cluster if ssh has been configured and the other hosts can be reached. The output of tpm diag will provide feedback detailing the hosts that were reached.

The structure of the created file will depend on the configured hosts, but will include all the logs for each accessible host configured in individual directories for each host.

Additional options

It is possible to limit the amount of information gathered by tpm diag by optionally skipping individual gather subroutines, or skipping entire groups. These are outlined below

  • --list : Print all diagnostic gathering groups and associated subroutines for use with --skip and --skipgroups

  • --include : Specify a comma-separated list of subroutines to include (NO spaces). Anything not listed will be skipped.

  • --skip : Specify a comma-separated list of subroutines to skip (NO spaces)

  • --groups : Specify a comma-separated list of subroutine groups to include (NO spaces). Anything not listed will be skipped.

  • --skipgroups : Specify a comma-separated list of subroutine groups to skip (NO spaces)

Examples

shell> tpm diag --list

GROUP: SUBROUTINE(s)
cluster:    cctrlClusterValidate cctrlHistoryFile cctrlLong cctrlPing cctrlStatus
general:    confDirs logFiles miscFiles
mysql:      etcMysql etcMycnf etcMyInclude etcMyIncludedirs getMysqlCommands mysqlErrorLog
os:         getOSCommands etcHosts cpuInfo etcSystemRelease
replicator: thlInfo thlIndex trepctlPerf trepctlQuick trepctlStatus trepctlStatusJSON
tpm:        etcTungsten tpmDiff tpmReverse tpmValidate

shell> tpm diag --skip=getOSCommands

shell> tpm diag --skipgroups=os

tungsten_send_diag

If the host you are running the diag from has external internet connectivity, you may also wish to consider using tungsten_send_diag. This will run tpm diag for you and automatically upload the resulting file to Continuent Support. For more information on using this, see Section 8.33, “The tungsten_send_diag Script”