joshelser opened a new pull request #1908:
URL: https://github.com/apache/hbase/pull/1908


   …ster
   
   While we never expect table descriptors to be missing, a corrupt meta
   (rogue merge daughters) or corrupt filesystem (missing tabledesc) can result 
in the master crashing before regions get assigned. We can guard against that 
happening with a simple null-check.
   
   I didn't try to reproduce this in a unit test, but I was able to reproduce 
it in a local environment doing the following:
   * `create 'usertable', 'family', {SPLITS => (1..n_splits).map{|i| 
"user#{i}"}}`
   * `(0..n_splits).map{|i| put 'usertable', "user#{i}", 'family:q', "#{i}"}`
   * Choose two regions in the table and use `merge_region` to merge them 
together (required!)
   * Kill everything (master and regionserver)
   * `hdfs dfs -mv /hbase/data/default/usertable/.tabledesc 
/sidelined-tabledesc`
   * Restart HBase
   * Observe master crash
   
   After this fix, the master stays up (and hbck can be used normally to 
generate a new tabledesc and reassign any regions stuck unassigned)
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to