Discovery
Environment discovery is a process that enables the CockroachDB Plugin to determine Cockroach installation details on a host. Whenever there is any changes (installing a new binary home) to an already set up environment in the Delphix application, environment refresh need to be performed.
Prerequisites
- Install delphix engine compatible with the CockroachDB plugin version as per support matrix
- Install CockroachDB binaries on staging and target servers.
- Installation of CRDB Plugin from here is required before the discovery.
CockroachDB Binaries Discovery
CockroachDB can be installed in different ways and so the installation path can vary in different environments. To discover correct software binaries information, we have the following options:
- Identify the CockroachDB repository through the default installation of CockroachDB on the staging or target host.
- Identify the CockroachDB repository through running CockroachDB instances (processes) on the staging or target host
- Identify the CockroachDB repository through the environment variable defined by the user on the staging or target host.
- Create a file name (if not present) .bash_profile or .bashrc in home directory of delphix OS user.
touch $HOME/.bash_profile $HOME/.bashrc
- Define environment variable pointing to binary path of CRDB_REPO directory on the host for manual discovery of CockroachDB instances and other information. Example as below:
echo "CRDB_REPO=/u01/cockroach/cockroach" > $HOME/.bash_profile
- In case of multiple CockroachDB versions installed on same host, provide all installations path separated with colon
(:)
to the environment variable defined in .bash_profile. Example as below:echo "CRDB_REPO=/u01/cockroach/cockroach:/u02/cockroach/cockroach" > $HOME/.bash_profile
- Create a file name (if not present) .bash_profile or .bashrc in home directory of delphix OS user.
Refresh Environment
Environment refresh will update the metadata associated with that environment and copies new plugin to the host.
Steps:
- Login to the Delphix Management application.
- Click Manage.
- Select Environments.
- In the Environments panel, click the name of the environment you want to refresh.
- Select the Refresh icon.
- In the Refresh confirmation dialog select Refresh.
- Once environment refresh is complete, click on the databases tab to view all the CockroachDB repositories identified by plugin discovery.
Sourceconfig
Every environment contains repositories
and each environment may have any number of repositories associated with it. Repository
represents the binaries for CockroachDB Instance. Each repository can have many SourceConfig
which represent CockroachDB instance. There is no sourceconfig generated automatically in CRDB plugin. We need to configure SourceConfig
objects through which we can create a dSource.