When you upgrade you need to keep the new hbase-default.xml file and
not overwrite it with the old one, the one shipped with 0.20.6 has
this:
<property>
<name>hbase.client.pause</name>
<value>1000</value>
<description>General client pause value. Used mostly as value to wait
before running a retry of a failed get, region lookup, etc.</description>
</property>
Which the value you're also looking for.
J-D
On Fri, Sep 24, 2010 at 12:17 PM, Katharine Chang
<[email protected]> wrote:
> I upgraded to 0.20.6 now and the sleep time is still 2000ms.
>
> Is there a way to configure the sleep time and what would be the suggested
> time?
>
> Thanks,
> Katharine
>
> On 9/24/2010 1:23 PM, Jean-Daniel Cryans wrote:
>>
>> The way it works (which is pretty rough), is that the client asks the
>> master to create the table and then checks the .META. table to find
>> out where it was assigned. If the region isn't assigned yet, the
>> client checks back later.
>>
>> The fact that your first sleep was 2000ms long indicates that you are
>> running an older version of HBase, I would recommend using 0.20.6 as
>> creating/disabling/enabling tables will be much faster and not as
>> spammy in your logs.
>>
>> J-D
>>
>> On Fri, Sep 24, 2010 at 8:38 AM, Katharine Chang
>> <[email protected]> wrote:
>>>
>>> I am running a standalone HBase server on a remote machine and tries
>>> to create tables using a Java client program.
>>>
>>> In the code, if the table already exists, then the table will be
>>> disabled and deleted and then get recreated.
>>>
>>> In the client log below, table "room" get disabled and deleted, but when
>>> creating the table, there is an exception
>>> (org.apache.hadoop.hbase.client.NoServerForRegionException).
>>>
>>> 2010-09-23 15:57:35,562 DEBUG [main]
>>> client.HConnectionManager$TableServers(690): locateRegionInMeta attempt
>>> 0 of 10 failed; retrying after sleep of 2000
>>> org.apache.hadoop.hbase.client.NoServerForRegionException: No server
>>> address listed in .META. for region room,,1285271855622
>>> at
>>>
>>> org.apache.hadoop.hbase.client.HConnectionManager$TableServers.locateRegionInMeta(HConnectionManager.java:668)
>>> at
>>>
>>> org.apache.hadoop.hbase.client.HConnectionManager$TableServers.locateRegion(HConnectionManager.java:594)
>>> at
>>>
>>> org.apache.hadoop.hbase.client.HConnectionManager$TableServers.locateRegion(HConnectionManager.java:557)
>>> at
>>>
>>> org.apache.hadoop.hbase.client.HBaseAdmin.createTable(HBaseAdmin.java:169)
>>>
>>> After the exception, the table "room" will still be created. But I
>>> wonder what is causing the exception. Why does it say "No server address
>>> listed in .META."?
>>>
>>> Thank you very much for your help,
>>> Katharine
>>>
>>> ==========================================
>>>
>>> 2010-09-23 15:57:33,125 DEBUG [main-EventThread]
>>> client.HConnectionManager$ClientZKWatcher(189): Got ZooKeeper event,
>>> state: SyncConnected, type: None, path: null
>>> 2010-09-23 15:57:33,125 DEBUG [main] zookeeper.ZooKeeperWrapper(336):
>>> Read ZNode /hbase/master got 141.212.113.36:60000
>>> 2010-09-23 15:57:33,234 DEBUG [main] zookeeper.ZooKeeperWrapper(336):
>>> Read ZNode /hbase/root-region-server got 141.212.113.36:56744
>>> 2010-09-23 15:57:33,250 DEBUG [main]
>>> client.HConnectionManager$TableServers(941): Found ROOT at
>>> 141.212.113.36:56744
>>> 2010-09-23 15:57:33,250 DEBUG [main]
>>> client.HConnectionManager$TableServers(849): Cached location address:
>>> 141.212.113.36:56744, regioninfo: REGION => {NAME => '.META.,,1',
>>> STARTKEY => '', ENDKEY => '', ENCODED => 1028785192, TABLE =>
>>> {{NAME =>
>>> '.META.', IS_META => 'true', MEMSTORE_FLUSHSIZE => '16384',
>>> FAMILIES =>
>>> [{NAME => 'historian', VERSIONS => '2147483647', COMPRESSION =>
>>> 'NONE',
>>> TTL => '604800', BLOCKSIZE => '8192', IN_MEMORY => 'false',
>>> BLOCKCACHE
>>> => 'false'}, {NAME => 'info', VERSIONS => '10', COMPRESSION =>
>>> 'NONE',
>>> TTL => '2147483647', BLOCKSIZE => '8192', IN_MEMORY => 'true',
>>> BLOCKCACHE => 'true'}]}}
>>> 2010-09-23 15:57:33,281 DEBUG [main]
>>> client.HConnectionManager$TableServers(733): Cache hit for row<> in
>>> tableName .META.: location server 141.212.113.36:56744, location region
>>> name .META.,,1
>>> 2010-09-23 15:57:33,296 DEBUG [main] zookeeper.ZooKeeperWrapper(336):
>>> Read ZNode /hbase/root-region-server got 141.212.113.36:56744
>>> 2010-09-23 15:57:33,296 DEBUG [main]
>>> client.HConnectionManager$TableServers(941): Found ROOT at
>>> 141.212.113.36:56744
>>> 2010-09-23 15:57:33,296 DEBUG [main]
>>> client.HConnectionManager$TableServers(849): Cached location address:
>>> 141.212.113.36:56744, regioninfo: REGION => {NAME => '.META.,,1',
>>> STARTKEY => '', ENDKEY => '', ENCODED => 1028785192, TABLE =>
>>> {{NAME =>
>>> '.META.', IS_META => 'true', MEMSTORE_FLUSHSIZE => '16384',
>>> FAMILIES =>
>>> [{NAME => 'historian', VERSIONS => '2147483647', COMPRESSION =>
>>> 'NONE',
>>> TTL => '604800', BLOCKSIZE => '8192', IN_MEMORY => 'false',
>>> BLOCKCACHE
>>> => 'false'}, {NAME => 'info', VERSIONS => '10', COMPRESSION =>
>>> 'NONE',
>>> TTL => '2147483647', BLOCKSIZE => '8192', IN_MEMORY => 'true',
>>> BLOCKCACHE => 'true'}]}}
>>> 2010-09-23 15:57:33,312 DEBUG [main]
>>> client.HConnectionManager$TableServers(510): Rowscanned=1, rowsOffline=0
>>> 2010-09-23 15:57:33,312 DEBUG [main] client.HBaseAdmin(397): Sleep.
>>> Waiting for all regions to be disabled from room
>>> 2010-09-23 15:57:35,312 DEBUG [main] client.HBaseAdmin(406): Wake.
>>> Waiting for all regions to be disabled from room
>>> 2010-09-23 15:57:35,312 DEBUG [main]
>>> client.HConnectionManager$TableServers(733): Cache hit for row<> in
>>> tableName .META.: location server 141.212.113.36:56744, location region
>>> name .META.,,1
>>> 2010-09-23 15:57:35,328 DEBUG [main]
>>> client.HConnectionManager$TableServers(510): Rowscanned=1, rowsOffline=1
>>> 2010-09-23 15:57:35,328 INFO [main] client.HBaseAdmin(414): Disabled
>>> room
>>> 2010-09-23 15:57:35,359 INFO [main] client.HBaseAdmin(302): Deleted room
>>> 2010-09-23 15:57:35,562 DEBUG [main]
>>> client.HConnectionManager$TableServers(690): locateRegionInMeta attempt
>>> 0 of 10 failed; retrying after sleep of 2000
>>> org.apache.hadoop.hbase.client.NoServerForRegionException: No server
>>> address listed in .META. for region room,,1285271855622
>>> at
>>>
>>> org.apache.hadoop.hbase.client.HConnectionManager$TableServers.locateRegionInMeta(HConnectionManager.java:668)
>>> at
>>>
>>> org.apache.hadoop.hbase.client.HConnectionManager$TableServers.locateRegion(HConnectionManager.java:594)
>>> at
>>>
>>> org.apache.hadoop.hbase.client.HConnectionManager$TableServers.locateRegion(HConnectionManager.java:557)
>>> at
>>>
>>> org.apache.hadoop.hbase.client.HBaseAdmin.createTable(HBaseAdmin.java:169)
>>> 2010-09-23 15:57:35,562 DEBUG [main]
>>> client.HConnectionManager$TableServers(810): Removed .META.,,1 for
>>> tableName=.META. from cache because of room,,99999999999999
>>> 2010-09-23 15:57:35,578 DEBUG [main]
>>> client.HConnectionManager$TableServers(849): Cached location address:
>>> 141.212.113.36:56744, regioninfo: REGION => {NAME => '.META.,,1',
>>> STARTKEY => '', ENDKEY => '', ENCODED => 1028785192, TABLE =>
>>> {{NAME =>
>>> '.META.', IS_META => 'true', MEMSTORE_FLUSHSIZE => '16384',
>>> FAMILIES =>
>>> [{NAME => 'historian', VERSIONS => '2147483647', COMPRESSION =>
>>> 'NONE',
>>> TTL => '604800', BLOCKSIZE => '8192', IN_MEMORY => 'false',
>>> BLOCKCACHE
>>> => 'false'}, {NAME => 'info', VERSIONS => '10', COMPRESSION =>
>>> 'NONE',
>>> TTL => '2147483647', BLOCKSIZE => '8192', IN_MEMORY => 'true',
>>> BLOCKCACHE => 'true'}]}}
>>> 2010-09-23 15:57:37,578 DEBUG [main]
>>> client.HConnectionManager$TableServers(849): Cached location address:
>>> 141.212.113.36:56744, regioninfo: REGION => {NAME =>
>>> 'room,,1285271855622', STARTKEY => '', ENDKEY => '', ENCODED =>
>>> 937432431, TABLE => {{NAME => 'room', FAMILIES => [{NAME =>
>>> 'usersName',
>>> COMPRESSION => 'NONE', VERSIONS => '1', TTL => '2147483647',
>>> BLOCKSIZE
>>> => '65536', IN_MEMORY => 'false', BLOCKCACHE => 'true'}]}}
>>> 2010-09-23 15:57:37,578 DEBUG [main] zookeeper.ZooKeeperWrapper(336):
>>> Read ZNode /hbase/root-region-server got 141.212.113.36:56744
>>> 2010-09-23 15:57:37,593 DEBUG [main]
>>> client.HConnectionManager$TableServers(941): Found ROOT at
>>> 141.212.113.36:56744
>>> 2010-09-23 15:57:37,593 DEBUG [main]
>>> client.HConnectionManager$TableServers(849): Cached location address:
>>> 141.212.113.36:56744, regioninfo: REGION => {NAME => '.META.,,1',
>>> STARTKEY => '', ENDKEY => '', ENCODED => 1028785192, TABLE =>
>>> {{NAME =>
>>> '.META.', IS_META => 'true', MEMSTORE_FLUSHSIZE => '16384',
>>> FAMILIES =>
>>> [{NAME => 'historian', VERSIONS => '2147483647', COMPRESSION =>
>>> 'NONE',
>>> TTL => '604800', BLOCKSIZE => '8192', IN_MEMORY => 'false',
>>> BLOCKCACHE
>>> => 'false'}, {NAME => 'info', VERSIONS => '10', COMPRESSION =>
>>> 'NONE',
>>> TTL => '2147483647', BLOCKSIZE => '8192', IN_MEMORY => 'true',
>>> BLOCKCACHE => 'true'}]}}
>>> 2010-09-23 15:57:37,593 DEBUG [main]
>>> client.HConnectionManager$TableServers(849): Cached location address:
>>> 141.212.113.36:56744, regioninfo: REGION => {NAME =>
>>> 'room,,1285271855622', STARTKEY => '', ENDKEY => '', ENCODED =>
>>> 937432431, TABLE => {{NAME => 'room', FAMILIES => [{NAME =>
>>> 'usersName',
>>> COMPRESSION => 'NONE', VERSIONS => '1', TTL => '2147483647',
>>> BLOCKSIZE
>>> => '65536', IN_MEMORY => 'false', BLOCKCACHE => 'true'}]}}
>>>
>>>
>