From c05c2e0b85f9a27a42da0d093fae9e61e5937e25 Mon Sep 17 00:00:00 2001 From: Wellington Ramos Chevreuil Date: Fri, 8 Dec 2023 12:05:17 +0000 Subject: [PATCH 1/2] HBASE-28251 [SFT] Add description for specifying SFT impl during snapshot recovery Change-Id: Ia36068783807d1e8f47c09feb4e9c5e0837b10b0 --- .../_chapters/bulk_data_generator_tool.adoc | 8 ++++---- .../_chapters/store_file_tracking.adoc | 18 ++++++++++++++++++ 2 files changed, 22 insertions(+), 4 deletions(-) diff --git a/src/main/asciidoc/_chapters/bulk_data_generator_tool.adoc b/src/main/asciidoc/_chapters/bulk_data_generator_tool.adoc index 3ac6ca693121..b04fcdeb7264 100644 --- a/src/main/asciidoc/_chapters/bulk_data_generator_tool.adoc +++ b/src/main/asciidoc/_chapters/bulk_data_generator_tool.adoc @@ -18,8 +18,8 @@ * limitations under the License. */ //// - -== Bulk Data Generator Tool +[[BulkDataGeneratorTool]] += Bulk Data Generator Tool :doctype: book :numbered: :toc: left @@ -29,7 +29,7 @@ This is a random data generator tool for HBase tables leveraging Hbase bulk load. It can create pre-splited HBase table and the generated data is *uniformly distributed* to all the regions of the table. -=== How to Use +== Usage [source] ---- @@ -53,7 +53,7 @@ hbase org.apache.hadoop.hbase.util.bulkdatagenerator.BulkDataGeneratorTool -t TE hbase org.apache.hadoop.hbase.util.bulkdatagenerator.BulkDataGeneratorTool -t TEST_TABLE -mc 10 -r 100 -sc 10 -Dmapreduce.map.memory.mb=8192 ---- -=== How it Works +== Overview ==== Table Schema Tool generates a HBase table with single column family, i.e. *cf* and 9 columns i.e. diff --git a/src/main/asciidoc/_chapters/store_file_tracking.adoc b/src/main/asciidoc/_chapters/store_file_tracking.adoc index 74d802f386c5..ab83f6b02b3d 100644 --- a/src/main/asciidoc/_chapters/store_file_tracking.adoc +++ b/src/main/asciidoc/_chapters/store_file_tracking.adoc @@ -143,3 +143,21 @@ example, that would be as follows: ---- alter 'my-table', CONFIGURATION => {'hbase.store.file-tracker.impl' => 'FILE'} ---- + +### Specifying trackers during snapshot recovery + +It's also possible to specify a given STORE FILE TRACKING implementation when recovering a snapshot +using the _clone_snasphot_ command. This is useful when recovering old snapshots, taken prior to a +change in the global configuration, or if the snapshot has been imported from a different cluster +that had a different STORE FILE TRACKING setting. Because snapshots preserve table and colum family +descriptors, a simple restore would reload the original configuration, requiring the additional +steps described above to convert the table/column family to the desired tracker implementation. +An example of how to use _clone_snapshot_ to specify the *FILE* tracker implementation +is shown below: + +---- +clone_snapshot 'snapshotName', 'namespace:tableName', {CLONE_SFT=>'FILE'} +---- + +NOTE: The option to specify the tracker during snapshot recovery is only available for the +_clone_snapshot_ command. The _restore_snapshot_ command does not support this parameter. From 2bdb1096a69d02e47d5af87de59aa94fcbd0980f Mon Sep 17 00:00:00 2001 From: Wellington Ramos Chevreuil Date: Fri, 8 Dec 2023 12:23:25 +0000 Subject: [PATCH 2/2] addressing Nihal's suggestions. Change-Id: I6fb0c9d98d21c774e741ba922ca4749d1fb9ec65 --- .../asciidoc/_chapters/store_file_tracking.adoc | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/src/main/asciidoc/_chapters/store_file_tracking.adoc b/src/main/asciidoc/_chapters/store_file_tracking.adoc index ab83f6b02b3d..b6c1f7e73399 100644 --- a/src/main/asciidoc/_chapters/store_file_tracking.adoc +++ b/src/main/asciidoc/_chapters/store_file_tracking.adoc @@ -146,12 +146,13 @@ alter 'my-table', CONFIGURATION => {'hbase.store.file-tracker.impl' => 'FILE'} ### Specifying trackers during snapshot recovery -It's also possible to specify a given STORE FILE TRACKING implementation when recovering a snapshot -using the _clone_snasphot_ command. This is useful when recovering old snapshots, taken prior to a -change in the global configuration, or if the snapshot has been imported from a different cluster -that had a different STORE FILE TRACKING setting. Because snapshots preserve table and colum family -descriptors, a simple restore would reload the original configuration, requiring the additional -steps described above to convert the table/column family to the desired tracker implementation. +It's also possible to specify a given store file tracking implementation when recovering a snapshot +using the _CLONE_SFT_ option of _clone_snasphot_ command. This is useful when recovering old +snapshots, taken prior to a change in the global configuration, or if the snapshot has been +imported from a different cluster that had a different store file tracking setting. +Because snapshots preserve table and colum family descriptors, a simple restore would reload +the original configuration, requiring the additional steps described above to convert the +table/column family to the desired tracker implementation. An example of how to use _clone_snapshot_ to specify the *FILE* tracker implementation is shown below: