Skip to main content
Common Reference

tpm query

Usage
tpm query [subcommand]

The tpm query command provides information about the current tpm installation. There are a number of subcommands to query specific information:

OptionDescriptionVersion
configReturn the full configuration values.
dataservicesReturn the list of dataservices.
defaultReturn the list of configured default values.
deploymentsReturn the configuration of al deployed hosts.
modified-filesReturn the list of files modified since installation by tpm
stagingReturn the staging directory from where Tungsten was installed.
topologyReturn the current topology.
usermapReturn the list of users organized by type from the user.map
valuesReturn the list of configured values.
versionGet the version of the current installation.

tpm query config

Returns a list of all of the configuration values, both user-specified and implied within the current configuration. The information is returned in the form of a JSON value:

shell> tpm query config
{
"__system_defaults_will_be_overwritten__": {
...
"staging_directory": "/home/tungsten/tungsten-clustering-8.0.4-132",
"staging_host": "tr-ms1",
"staging_user": "tungsten"
}

tpm query dataservices

Returns the list of configured dataservices that have, or will be, installed:

shell> tpm query dataservices
alpha : PHYSICAL

tpm query deployments

Returns a list of all the individual deployment hosts and configuration information, returned in the form of a JSON object for each installation host:

shell> tpm query deployments
{
"config_target_basename": "tungsten-clustering-8.0.4-132_pid22729",
"dataservice_host_options": {
"alpha": {
"start": "true"
}
...
"staging_directory": "/home/tungsten/tungsten-clustering-8.0.4-132",
"staging_host": "tr-ms1",
"staging_user": "tungsten"
}

tpm query modified-files

Shows the list of configuration files that have been modified since the installation was completed. Modified configuration files cannot be overwritten during an upgrade process, using this command enables you identify which files contain changes so that these modifications can be manually migrated to the new installation. To restore or replace files with their original installation, copy the .filename.orig file.

tpm query staging

Returns the host and directory from which the current installation was created:

shell> tpm query staging
tungsten@host1:/home/tungsten/tungsten-clustering-8.0.4-132

This can be useful when the installation host and directory from which the original configuration was made need to be updated or modified.

For convenience, the following command will take you straight to the directory:

shell> cd `tpm query staging | cut -d: -f2`

tpm query topology

Returns the current topology and list of configured servers and roles in the form of a JSON object:

shell> tpm query topology
{
"host1": "slave",
"host2": "slave",
"host3": "master"
}

tpm query usermap

Applies to: Tungsten Clustering for MySQL

Returns a summarized list of the currently configured users in the user.map

shell> tpm query usermap
# user.map Summary

# Configured users
app_user ******** alpha

# Script entries


# DirectRead users


# Host-based routing entries

tpm query version

Returns the version of the installed software:

shell> tpm query version
8.0.4-132