table replica add
Registers a table as a replica of another HPE Ezmeral Data Fabric Database binary or JSON table.
table replica
autosetup
command. Permissions Required
To run this command, your user ID must have the following permissions:
readAce
andwriteAce
on both the source volume and the target volumelookupdir
on directories in the paths of both tablesreadperm
andreplperm
permissions on the source table
Syntax
- CLI
-
/opt/mapr/bin/maprcli table replica add -path <table path> -replica <replica table path> [ -columns <comma separated list of <family>[:<column>]> ] [ -paused <is replication paused> default: false ] [ -throttle <throttle replication ops> default: false> ] [ -networkencryption <enable on-wire encryption> default: false> ] [ -synchronous <is synchronous replication> default: false ] [ -networkcompression <on-wire compression type: off|on|lzf|lz4|zlib> default: on ]
- REST
-
curl -k -X POST 'http[s]://<host>:<port>/rest/table/replica/add?path=<path>&replica=<name>&<parameters> -u <username>:<password>
Parameters
Parameter | Description |
---|---|
path |
The path to the source table that you want to replicate.
|
replica |
The path to the replica.
NOTE For replication to a table, the command will fail if the table in the replica
path does not exist. |
columns |
By default, all columns in the source table are replicated. If you do not want to replicate all columns in the table, you can
specify specific columns to replicate:
|
paused |
A Boolean value that specifies whether to pause the replication so that it does
not start immediately. The replication can be resumed using the replica resume
command at a later time. The values are |
throttle | A Boolean value that specifies whether to throttle replication operations.
Throttle the replication stream to minimize the impact of the replication process on
incoming operations during periods of heavy load. The values are true or false.
Default: No throttle (false ) |
networkencryption | A Boolean value that specifies whether or not to enable on-wire encryption. The
values are true or false . If you set this to
true , the local cluster and any other cluster that is part of the
replication process must be enabled for security. Default: No encryption (false) |
synchronous |
A Boolean value that specifies whether replication is synchronous or
asynchronous. The values are |
networkcompression |
The type of on-wire compression. Default: on The types are:
The default compression is lz4, which can be set by specifying
|
Example
Registers a table on the local cluster as a replica of another table on the local cluster:
- CLI
-
/opt/mapr/bin/maprcli table replica add -path /volume1/custA -replica /volume2/custA
- REST
-
curl -k -X POST \ 'https://r1n1.sj.us:8443/rest/table/replica/add?path=%2Fvolume1%2FcustA&replica=%2Fvolume2%2FcustA' \ -u mapr:mapr