Show Master Database Information

You can display information for a master database.

Using ttRepAdmin to Display Information About the Master Database

Use the ttRepAdmin utility with the -self -list options to display information about the master database.

ttRepAdmin -dsn masterDSN -self -list

This example uses ttRepAdmin to display information about the master database described in Multiple Subscriber Classic Replication Schemes.

> ttRepAdmin -dsn masterds -self -list
Self host "server1", port auto, name "masterds", LSN 0/2114272

The following table describes the fields.

Field Description

host

The name of the host for the database.

port

TCP/IP port used by a replication agent of another database to receive updates from this database. A value of 0 (zero) indicates replication has automatically assigned the port.

name

Name of the database.

Log file/Replication hold LSN

Indicates the oldest location in the transaction log that is held for possible transmission to the subscriber. A value of -1/-1 indicates replication is in the stop state with respect to all subscribers.

Querying Replication Tables to Obtain Information About a Master Database

Use a SELECT statement to query the TTREP.TTSTORES and TTREP.REPSTORES replication tables to obtain information about a master database.

SELECT t.host_name, t.rep_port_number, t.tt_store_name
  FROM ttrep.ttstores t, ttrep.repstores s
    WHERE t.is_local_store = 0x01
      AND t.tt_store_id = s.tt_store_id;

This is the output of the SELECT statement for the master database described in Multiple Subscriber Classic Replication Schemes. The fields are the host name, the replication port number, and the database name.

< server1, 0, masterds>