Details
Description
Disabling sanity checks on a table is ignored when restoring snapshots. If this is expected behavior at least the error message is misleading.
Steps to Reproduce
- Create a new table
create 't', 'cf' - Add a coprocessor to the newly created table
alter 't', METHOD => 'table_att', 'coprocessor' => 'coprocessor.jar|com.example.MyCoprocessor|0' - Create a snapshot
snapshot 't', 'snapshot-t' - Disable the table to prevent region servers from crashing in the next step
disable 't' - Delete the coprocessor JAR and restart HBase.
- Attempt to restore the snapshot leads to failing sanity check as expected
restore_snapshot 'snapshot-t'
ERROR: org.apache.hadoop.hbase.DoNotRetryIOException: coprocessor.jar Set hbase.table.sanity.checks to false at conf or table descriptor if you want to bypass sanity checks [...] - Disable sanity checks (as described in the error message) and retry
alter 't', CONFIGURATION => {'hbase.table.sanity.checks' => 'false'}
restore_snapshot 'snapshot-t'
Expected Behavior
The snapshot is restored.
Actual Behavior
The same error message as in step 6. is shown.