The procedures in this section are designed for the Multi-Site/Active-Active topology ONLY. Do NOT use these procedures for Composite Active/Active Clustering using v6 onwards.
For version 6.x onwards, Composite Active/Active Clustering, please refer to Section 3.4, “Deploying Composite Active/Active Clusters”
Creating the configuration requires two distinct steps, the first to create the two Tungsten Cluster deployments, and a second that creates the Tungsten Replicator configurations on different network ports, and different install directories.
Install the Tungsten Cluster and Tungsten Replicator packages or download the tarballs, and unpack them:
shell>cd /opt/continuent/software
shell>tar zxf
shell>tungsten-clustering-7.0.3-141.tar.gz
tar zxf
tungsten-replicator-7.0.3-141.tar.gz
Change to the Tungsten Cluster directory:
shell> cd tungsten-clustering-7.0.3-141
Run tpm to configure the installation. This method assumes you are using the Section 10.3, “tpm Staging Configuration” method:
Click the link below to switch examples between Staging and INI methods
For ini install, the ini file contains all the configuration for both the cluster deployment and the replicator deployment.
For a staging install, you first use the cluster configuration show below and then configure the replicator as a separate process. These additional steps are outlined below
shell>./tools/tpm configure defaults \ --reset \ --user=tungsten \ --install-directory=/opt/continuent \ --replication-user=tungsten \ --replication-password=secret \ --replication-port=3306 \ --profile-script=~/.bashrc \ --application-user=app_user \ --application-password=secret \ --skip-validation-check=MySQLPermissionsCheck \ --rest-api-admin-user=apiuser \ --rest-api-admin-pass=secret
shell>./tools/tpm configure east \ --topology=clustered \ --connectors=east1,east2,east3 \ --master=east1 \ --members=east1,east2,east3
shell>./tools/tpm configure west \ --topology=clustered \ --connectors=west1,west2,west3 \ --master=west1 \ --members=west1,west2,west3
shell> vi /etc/tungsten/tungsten.ini
[defaults] user=tungsten install-directory=/opt/continuent replication-user=tungsten replication-password=secret replication-port=3306 profile-script=~/.bashrc application-user=app_user application-password=secret skip-validation-check=MySQLPermissionsCheck rest-api-admin-user=apiuser rest-api-admin-pass=secret
[defaults.replicator] home-directory=/opt/replicator rmi-port=10002 executable-prefix=mm
[east] topology=clustered connectors=east1,east2,east3 master=east1 members=east1,east2,east3
[west] topology=clustered connectors=west1,west2,west3 master=west1 members=west1,west2,west3
[east_west] topology=cluster-slave master-dataservice=east slave-dataservice=west thl-port=2113
[west_east] topology=cluster-slave master-dataservice=west slave-dataservice=east thl-port=2115
Configuration group defaults
The description of each of the options is shown below; click the icon to hide this detail:
For staging configurations, deletes all pre-existing configuration information between updating with the new configuration values.
System User
--install-directory=/opt/continuent
install-directory=/opt/continuent
Path to the directory where the active deployment will be installed. The configured directory will contain the software, THL and relay log information unless configured otherwise.
For databases that required authentication, the username to use when connecting to the database using the corresponding connection method (native, JDBC, etc.).
The password to be used when connecting to the database using
the corresponding
--replication-user
.
The network port used to connect to the database server. The default port used depends on the database being configured.
Append commands to include env.sh in this profile script
Database username for the connector
Database password for the connector
--skip-validation-check=MySQLPermissionsCheck
skip-validation-check=MySQLPermissionsCheck
The --skip-validation-check
disables a given validation check. If any validation check
fails, the installation, validation or configuration will
automatically stop.
Using this option enables you to bypass the specified check, although skipping a check may lead to an invalid or non-working configuration.
You can identify a given check if an error or warning has been raised during configuration. For example, the default table type check:
... ERROR >> centos >> The datasource root@centos:3306 (WITH PASSWORD) » uses MyISAM as the default storage engine (MySQLDefaultTableTypeCheck) ...
The check in this case is
MySQLDefaultTableTypeCheck
,
and could be ignored using
--skip-validation-check=MySQLDefaultTableTypeCheck
.
Setting both
--skip-validation-check
and
--enable-validation-check
is
equivalent to explicitly disabling the specified check.
Configuration group defaults.replicator
The description of each of the options is shown below; click the icon to hide this detail:
--home-directory=/opt/replicator
home-directory=/opt/replicator
Path to the directory where the active deployment will be installed. The configured directory will contain the software, THL and relay log information unless configured otherwise.
Replication RMI listen port
When enabled, the supplied prefix is added to each command alias
that is generated for a given installation. This enables
multiple installations to co-exist and and be accessible through
a unique alias. For example, if the executable prefix is
configured as east
, then
an alias for the installation to trepctl will
be created as east_trepctl.
Alias information for executable prefix data is stored within
the
$CONTINUENT_ROOT/share/aliases.sh
file for each installation.
Configuration group east
The description of each of the options is shown below; click the icon to hide this detail:
Replication topology for the dataservice.
--connectors=east1,east2,east3
Hostnames for the dataservice connectors
The hostname of the primary (extractor) within the current service.
Hostnames for the dataservice members
Configuration group west
The description of each of the options is shown below; click the icon to hide this detail:
Replication topology for the dataservice.
--connectors=west1,west2,west3
Hostnames for the dataservice connectors
The hostname of the primary (extractor) within the current service.
Hostnames for the dataservice members
Configuration group east_west
The description of each of the options is shown below; click the icon to hide this detail:
Replication topology for the dataservice.
Dataservice name to use as a relay source
Dataservice to use to determine the value of host configuration
Port to use for THL Operations
Configuration group west_east
The description of each of the options is shown below; click the icon to hide this detail:
Replication topology for the dataservice.
Dataservice name to use as a relay source
Dataservice to use to determine the value of host configuration
Port to use for THL Operations
If you plan to make full use of the REST API (which is enabled by default) you will need to also configure a username and password for API Access. This must be done by specifying the following options in your configuration:
rest-api-admin-user=tungsten rest-api-admin-pass=secret
Run tpm to install the software with the configuration.
shell > ./tools/tpm install
During the startup and installation, tpm will notify you of any problems that need to be fixed before the service can be correctly installed and started. If the service starts correctly, you should see the configuration and current status of the service.
Change to the Tungsten Replicator directory:
shell> cd tungsten-replicator-7.0.3-141
Run tpm to configure the installation. This method assumes you are using the Section 10.3, “tpm Staging Configuration” method:
If you are running a staging install, first configure the replicator using the following example, if configuring using an ini file, skip straight to the install step below
shell>./tools/tpm configure defaults \ --reset \ --user=tungsten \ --install-directory=/opt/replicator \ --replication-user=tungsten \ --replication-password=secret \ --replication-port=3306 \ --profile-script=~/.bashrc \ --application-user=app_user \ --application-password=secret \ --skip-validation-check=MySQLPermissionsCheck \ --rmi-port=10002 \ --executable-prefix=mm \ --thl-port=2113 \ --rest-api-admin-user=apiuser \ --rest-api-admin-pass=secret
shell>./tools/tpm configure east \ --topology=clustered \ --connectors=east1,east2,east3 \ --master=east1 \ --members=east1,east2,east3
shell>./tools/tpm configure west \ --topology=clustered \ --connectors=west1,west2,west3 \ --master=west1 \ --members=west1,west2,west3
shell>./tools/tpm configure east_west \ --topology=cluster-slave \ --master-dataservice=east \ --slave-dataservice=west \ --thl-port=2113
shell>./tools/tpm configure west_east \ --topology=cluster-slave \ --master-dataservice=west \ --slave-dataservice=east \ --thl-port=2115
Run tpm to install the software with the configuration.
shell > ./tools/tpm install
During the startup and installation, tpm will notify you of any problems that need to be fixed before the service can be correctly installed and started. If the service starts correctly, you should see the configuration and current status of the service.
Initialize your PATH
and environment.
shell>source /opt/continuent/share/env.sh
shell>source /opt/replicator/share/env.sh
The Multi-Site/Active-Active clustering should be installed and ready to use.