[ 
https://issues.apache.org/jira/browse/HBASE-23909?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17049986#comment-17049986
 ] 

Viraj Jasani commented on HBASE-23909:
--------------------------------------

With master branch, I am not able to repro this. Some regions are stuck in 
trasition, so the output comes like this:
{code:java}
hbase(main):045:0> list_regions 'cluster_test'
                      SERVER_NAME |                                             
              REGION_NAME |  START_KEY |    END_KEY |   SIZE |    REQ |   
LOCALITY |
 -------------------------------- | 
--------------------------------------------------------------------- | 
---------- | ---------- | ------ | ------ | ---------- |
 192.168.0.11,16020,1583163575251 |         
cluster_test,,1583164529046.52e3fd6c5ab61243bede88fc4be4eeff. |            |   
11111111 | 87.0MB | 368475 |        0.0 |
 192.168.0.11,16022,1583164478554 | 
cluster_test,11111111,1583164529046.a573e43127c6688571dbe7a3c091d05d. |   
11111111 |   22222222 | 90.0MB | 361629 |        0.0 |
 192.168.0.11,16022,1583164478554 | 
cluster_test,22222222,1583164529046.891f4306705167e172f30521a1f79abd. |   
22222222 |   33333333 | 91.0MB | 363108 |        0.0 |
 192.168.0.11,16020,1583163575251 | 
cluster_test,33333333,1583164529046.36d6413ce52c794499c92cca3d929d85. |   
33333333 |   44444444 | 88.0MB | 361172 |        0.0 |
 192.168.0.11,16020,1583163575251 | 
cluster_test,44444444,1583164529046.a54a3919ecd8413795cd5f56cf19ec69. |   
44444444 |   55555555 | 90.0MB | 357253 |        0.0 |
 192.168.0.11,16023,1583164485661 | 
cluster_test,55555555,1583164529046.3f65c6959be9758912c47ed5c590de0a. |   
55555555 |   66666666 | 91.0MB | 361120 |        0.0 |
 192.168.0.11,16020,1583163575251 | 
cluster_test,66666666,1583164529046.42870b0f9d4a0feb52671f453bc8df3d. |   
66666666 |   77777777 | 87.0MB | 360445 |        0.0 |
 192.168.0.11,16022,1583164478554 | 
cluster_test,77777777,1583164529046.a9c16e7c01be8bcd4ef2e6f24e3923a8. |   
77777777 |   88888888 | 90.0MB | 360730 |        0.0 |
 192.168.0.11,16020,1583163575251 | 
cluster_test,88888888,1583164529046.3b2635a2badbe6696b03d873c19cc973. |   
88888888 |   99999999 | 90.0MB | 360782 |        0.0 |
 192.168.0.11,16023,1583164485661 | 
cluster_test,99999999,1583164529046.8f8d95b7feb93258885c4447f0323478. |   
99999999 |   aaaaaaaa | 90.0MB | 362916 |        0.0 |
 192.168.0.11,16023,1583164485661 | 
cluster_test,aaaaaaaa,1583164529046.61c19999fc1c67b7425909c24ad3d1d4. |   
aaaaaaaa |   bbbbbbbb | 90.0MB | 357401 |        0.0 |
 192.168.0.11,16022,1583164478554 | 
cluster_test,bbbbbbbb,1583164529046.466714dc98a02024d93ee938c1d304e1. |   
bbbbbbbb |   cccccccc | 87.0MB | 362035 |        0.0 |
 192.168.0.11,16022,1583164478554 | 
cluster_test,cccccccc,1583164529046.a05513e8d1e6a5c416c218ae9ff32e8b. |   
cccccccc |   dddddddd | 87.0MB | 364605 |        0.0 |
 192.168.0.11,16023,1583164485661 | 
cluster_test,dddddddd,1583164529046.2d1e981a15e5aa80d3cf82be88e8940d. |   
dddddddd |   eeeeeeee | 87.0MB | 365299 |        0.0 |
 192.168.0.11,16023,1583164485661 | 
cluster_test,eeeeeeee,1583164529046.9bd81b904159056d3711e825b41b4feb. |   
eeeeeeee |            | 87.0MB | 367030 |        0.0 |
 15 rows
Took 0.0341 seconds                                                             
                                                                                
                                                                              
hbase(main):046:0> split 'cluster_test'
Took 4.4739 seconds                                                             
                                                                                
                                                                              
hbase(main):047:0> list_regions 'cluster_test'
Can not find all details for region: 
cluster_test,22222222,1583164870234.32f05c5dce094f51f85ca4c80f671244. , it may 
be disabled or in transition
Can not find all details for region: 
cluster_test,2ab0d800860461475f59d866202dc6d9-85636,1583164870234.73ce2cf66484cf4955187e65396d5ebe.
 , it may be disabled or in transition
Can not find all details for region: 
cluster_test,77777777,1583164870233.bbfc61d7cfbe29ac92aad9b6a98608a9. , it may 
be disabled or in transition
Can not find all details for region: 
cluster_test,800f569916f0f5c1e487a9b5e976bdc4-29597,1583164870233.dc1b398b32537bdd2ee518c33fd1f538.
 , it may be disabled or in transition
Can not find all details for region: 
cluster_test,99999999,1583164870262.f997e80eda8dc47bd66d86f9a9a4726f. , it may 
be disabled or in transition
Can not find all details for region: 
cluster_test,a222168483af36c9ad47e59b0370953c-60382,1583164870262.8cd1ff9d40b87c7ac0e6eea246e36965.
 , it may be disabled or in transition
Can not find all details for region: 
cluster_test,dddddddd,1583164870263.a369f14840289975947eb230eee814cd. , it may 
be disabled or in transition
Can not find all details for region: 
cluster_test,e66c60de95c9371fbabd7da9944984a3-82953,1583164870263.64292725e37d2b680f9075cfa14de278.
 , it may be disabled or in transition
                      SERVER_NAME |                                             
                                             REGION_NAME |                      
         START_KEY |                                 END_KEY |    SIZE |   REQ 
|   LOCALITY |
 -------------------------------- | 
----------------------------------------------------------------------------------------------------
 | --------------------------------------- | 
--------------------------------------- | ------- | ----- | ---------- |
 192.168.0.11,16020,1583163575251 |                                        
cluster_test,,1583164870108.14c2858c3f5ee3dbf17a880aaab6b12b. |                 
                        | 08935d4a81cc96bd093e8ec43125ec35-356181 | 125.0MB |   
  0 |        0.0 |
 192.168.0.11,16020,1583163575251 | 
cluster_test,08935d4a81cc96bd093e8ec43125ec35-356181,1583164870108.42e301dcdffbcbe2c22721dbba4bf10b.
 | 08935d4a81cc96bd093e8ec43125ec35-356181 |                                
11111111 | 125.0MB |     0 |        0.0 |
 192.168.0.11,16022,1583164478554 |                                
cluster_test,11111111,1583164870233.6a3cd5e770de6679aa545a652267e418. |         
                       11111111 |  198cd1d02b809ca426766c40d1d42df9-99489 | 
124.0MB |     0 |        0.0 |
 192.168.0.11,16022,1583164478554 |  
cluster_test,198cd1d02b809ca426766c40d1d42df9-99489,1583164870233.bcf34b01716deea7b7a76435569e322b.
 |  198cd1d02b809ca426766c40d1d42df9-99489 |                                
22222222 | 124.0MB |     0 |        0.0 |
 192.168.0.11,16022,1583164478554 |                                
cluster_test,22222222,1583164870234.32f05c5dce094f51f85ca4c80f671244. |         
                       22222222 |  2ab0d800860461475f59d866202dc6d9-85636 |     
    |       |            |
 192.168.0.11,16022,1583164478554 |  
cluster_test,2ab0d800860461475f59d866202dc6d9-85636,1583164870234.73ce2cf66484cf4955187e65396d5ebe.
 |  2ab0d800860461475f59d866202dc6d9-85636 |                                
33333333 |         |       |            |
 192.168.0.11,16020,1583163575251 |                                
cluster_test,33333333,1583164870108.782097a367bc9e41a50bdb7c400ec8ba. |         
                       33333333 | 3ba9a607ad2d5216b12d91ac92519a00-612048 | 
123.0MB |     0 |        0.0 |
 192.168.0.11,16020,1583163575251 | 
cluster_test,3ba9a607ad2d5216b12d91ac92519a00-612048,1583164870108.a23a8d2e2fc613f67167f870738e96a5.
 | 3ba9a607ad2d5216b12d91ac92519a00-612048 |                                
44444444 | 123.0MB |     0 |        0.0 |
 192.168.0.11,16020,1583163575251 |                                
cluster_test,44444444,1583164870108.00a82be4e4d3f66fc85d185f4d66b7e1. |         
                       44444444 |  4cd5d8649bb4fc55c173cffa04d2e849-50359 | 
122.0MB |     0 |        0.0 |
 192.168.0.11,16020,1583163575251 |  
cluster_test,4cd5d8649bb4fc55c173cffa04d2e849-50359,1583164870108.5449f6ae4716bbfe04c752f0f19b0371.
 |  4cd5d8649bb4fc55c173cffa04d2e849-50359 |                                
55555555 | 122.0MB |     0 |        0.0 |
 192.168.0.11,16023,1583164485661 |                                
cluster_test,55555555,1583164870263.a92cd9e93ce88496183e0aa214139505. |         
                       55555555 | 5dccc93676f3bb3d165a33aac7f4fa77-425269 | 
125.0MB |     0 |        0.0 |
{code}
 

However, I see that we have already backported this to branch-1 last year: 
[https://github.com/apache/hbase/commit/ac807d7fe53e000aa3bc7be93df9b16028efddce]

 

Let me try to reproduce today with branch-1.

> list_regions fails if table is under split
> ------------------------------------------
>
>                 Key: HBASE-23909
>                 URL: https://issues.apache.org/jira/browse/HBASE-23909
>             Project: HBase
>          Issue Type: Bug
>          Components: shell
>    Affects Versions: 1.6.0
>            Reporter: Peter Somogyi
>            Priority: Minor
>
> Shortly after executing split 'table' command from the shell the list_regions 
> 'table' fails with "ERROR: undefined method `toString' for nil:NilClass"
>  
> {noformat}
> hbase(main):002:0> list_regions 'cluster_test'
>                  SERVER_NAME |                                                
>            REGION_NAME |  START_KEY |    END_KEY |  SIZE |      REQ |   
> LOCALITY |
>  --------------------------- | 
> --------------------------------------------------------------------- | 
> ---------- | ---------- | ----- | -------- | ---------- |
>  nokedli,34665,1582736360668 |         
> cluster_test,,1582736408029.857a9b734a2f490e573ba20b1bbf99b3. |            |  
>  33333333 |  3348 | 20408042 |        0.0 |
>  nokedli,34665,1582736360668 | 
> cluster_test,33333333,1582736408029.1749360028b3a5e76b5da1d1888e5b9d. |   
> 33333333 |   66666666 |  3321 | 20242123 |        0.0 |
>  nokedli,34665,1582736360668 | 
> cluster_test,66666666,1582736408029.1f1366aa0ee621d496103ac5a50bca77. |   
> 66666666 |   99999999 |  3316 | 20215774 |        0.0 |
>  nokedli,34665,1582736360668 | 
> cluster_test,99999999,1582736408029.ae95589c9498443a89aea4c42c199372. |   
> 99999999 |   cccccccc |  3327 | 20285312 |        0.0 |
>  nokedli,34665,1582736360668 | 
> cluster_test,cccccccc,1582736408029.239647c37e27cbd3154180ce5004a1ea. |   
> cccccccc |            |  3355 | 20451469 |        0.0 |
>  5 rows
> hbase(main):003:0> split 'cluster_test'
> 0 row(s) in 0.2240 seconds
> hbase(main):004:0> list_regions 'cluster_test'
> ERROR: undefined method `toString' for nil:NilClass
> Here is some help for this command:
>         List all regions for a particular table as an array and also filter 
> them by server name (optional) as prefix
>         and maximum locality (optional). By default, it will return all the 
> regions for the table with any locality.
>         The command displays server name, region name, start key, end key, 
> size of the region in MB, number of requests
>         and the locality. The information can be projected out via an array 
> as third parameter. By default all these information
>         is displayed. Possible array values are SERVER_NAME, REGION_NAME, 
> START_KEY, END_KEY, SIZE, REQ and LOCALITY. Values
>         are not case sensitive. If you don't want to filter by server name, 
> pass an empty hash / string as shown below.
>         Examples:
>         hbase> list_regions 'table_name'
>         hbase> list_regions 'table_name', 'server_name'
>         hbase> list_regions 'table_name', {SERVER_NAME => 'server_name', 
> LOCALITY_THRESHOLD => 0.8}
>         hbase> list_regions 'table_name', {SERVER_NAME => 'server_name', 
> LOCALITY_THRESHOLD => 0.8}, ['SERVER_NAME']
>         hbase> list_regions 'table_name', {}, ['SERVER_NAME', 'start_key']
>         hbase> list_regions 'table_name', '', ['SERVER_NAME', 'start_key']
> hbase(main):005:0> list_regions 'cluster_test'
>                  SERVER_NAME |                                                
>                                           REGION_NAME |                       
>         START_KEY |                                 END_KEY |  SIZE |      
> REQ |   LOCALITY |
>  --------------------------- | 
> ----------------------------------------------------------------------------------------------------
>  | --------------------------------------- | 
> --------------------------------------- | ----- | -------- | ---------- |
>  nokedli,34665,1582736360668 |                                        
> cluster_test,,1582878981608.614acededc61f55a10816bb871d0421b. |               
>                           | 197f83f2390a2a0c4104f4630982c585-461828 |  3348 | 
> 10204021 |        0.0 |
>  nokedli,34665,1582736360668 | 
> cluster_test,197f83f2390a2a0c4104f4630982c585-461828,1582878981608.5987f972793bd422564a0758e545caa5.
>  | 197f83f2390a2a0c4104f4630982c585-461828 |                                
> 33333333 |  3348 | 10204021 |        0.0 |
>  nokedli,34665,1582736360668 |                                
> cluster_test,33333333,1582878982425.a306381f3ee03161dc832eaca066131b. |       
>                          33333333 | 4cdfa653a3843d49a62004a6e4e71636-501997 | 
>  3321 | 10121061 |        0.0 |
>  nokedli,34665,1582736360668 | 
> cluster_test,4cdfa653a3843d49a62004a6e4e71636-501997,1582878982425.ae87e47584e3dee98e524f961fa6906e.
>  | 4cdfa653a3843d49a62004a6e4e71636-501997 |                                
> 66666666 |  3321 | 10121061 |        0.0 |
>  nokedli,34665,1582736360668 |                                
> cluster_test,66666666,1582878983449.d4015a18e47a9aeec89a1ead9a974186. |       
>                          66666666 | 7ffd66580ac07b1ff7636f9b15609fa6-238805 | 
>  3316 | 10107887 |        0.0 |
>  nokedli,34665,1582736360668 | 
> cluster_test,7ffd66580ac07b1ff7636f9b15609fa6-238805,1582878983449.c92f8a7b3a89fee59313bdb516720319.
>  | 7ffd66580ac07b1ff7636f9b15609fa6-238805 |                                
> 99999999 |  3316 | 10107887 |        0.0 |
>  nokedli,34665,1582736360668 |                                
> cluster_test,99999999,1582878984099.36d0e3d56119f2bdcae280853c29321d. |       
>                          99999999 | b36cb3f90c3019779ba5a3b00fb6da2f-320789 | 
>  3327 | 10142656 |        0.0 |
>  nokedli,34665,1582736360668 | 
> cluster_test,b36cb3f90c3019779ba5a3b00fb6da2f-320789,1582878984099.9d76372540e628675a4aea5a8979107d.
>  | b36cb3f90c3019779ba5a3b00fb6da2f-320789 |                                
> cccccccc |  3327 | 10142656 |        0.0 |
>  nokedli,34665,1582736360668 |                                
> cluster_test,cccccccc,1582878984966.1292a5f5dbd5f454d5d3b3cf048c4a75. |       
>                          cccccccc |  e66d48d7b227e7845b73d43eb1a06fcb-86032 | 
>  3355 | 10225734 |        0.0 |
>  nokedli,34665,1582736360668 |  
> cluster_test,e66d48d7b227e7845b73d43eb1a06fcb-86032,1582878984966.6765ff09c59899363ae9be115a9c3d78.
>  |  e66d48d7b227e7845b73d43eb1a06fcb-86032 |                                  
>        |  3355 | 10225734 |        0.0 |
>  10 rowshbase(main):006:0>{noformat}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to