cbrestoreツールは 、ファイルからクラスタ全体またはクラスタ内の単一のバケットにデータを復元します。ディスク上のファイルに書かれていたアイテムがRAMに復元されます。ツールは使用しているプラットフォームに応じて、以下の場所にあります。
| Linux |
/opt/couchbase/bin/cbrestore
|
| Windows |
C:\Program Files\Couchbase\Server\bin\cbrestore
|
| Mac OS X |
/Applications/Couchbase Server.app/Contents/Resources/couchbase-core/bin/cbrestore
|
cbrestoreコマンドの形式は次のとおりです:
cbrestore [options] [source] [destination]ここで:
[options]
リストア操作のための1つ以上のオプション。表7.6「cbrestore コマンドラインオプション」を参照してください。
[source]
バックアップデータのソース。これはcbbackupを使用して作成されたバックアップのあるディレクトリとする必要があります。
[destination]
復元する情報の宛先。これは、既存クラスタ内のノードのREST APIのURLである必要があります。単一ノードにデータを復元する時、あなたがリストアしたいノードである必要があります。バケット全体を復元する時、クラスタ内のノードのいずれかのURLを指定する必要があります。
cbrestoreのオプションの一覧を次の表に示します。
表7.6 cbrestore コマンドラインオプション
| Format | Description |
|---|---|
-a, --add | Add the data to the existing bucket data, rather than using set and overwriting existing items. |
-p, --password | REST password for the cluster or node. |
-u, --username | REST username for the cluster or node. |
-i, --id | Restore only items that match a specified vBucket ID. |
-v, --verbose | Verbose logging of the progress. Using the option multpple times increases the amount of logging produced. |
-t, --threads | Specify the number of concurrent threads to be used when performing the backup. |
-n, --dry-run | Perform a dry run; validates parameters, files and configuration, but performs no backup. |
-h, --help | Display help message and exit. |
-k, --key | Key name or regular expression to limit the items restored. |
-B, --bucket-destination | Name of the bucket to write the restored data to. |
-b, --bucket-source | Name of the bucket containing the data to be restored. |
cbrestoreの使用方法の詳細については、「cbrestoreツールを使用したリストア」を参照してください。