I managed fix this issue on my machine. If you notice the startup script of
*local* regionservers (bin/local-regionservers.sh).

run_regionserver () {

  DN=$2

  export HBASE_IDENT_STRING="$USER-$DN"

  HBASE_REGIONSERVER_ARGS="\

    -D hbase.regionserver.port=`expr 16200 + $DN` \

    -D hbase.regionserver.info.port=`expr 16300 + $DN`"

  "$bin"/hbase-daemon.sh  --config "${HBASE_CONF_DIR}" $1 regionserver
$HBASE_REGIONSERVER_ARGS

}


We put hbase.regionserver.port = 16200 + num (1 for localhost) and we call
this script as follows


regionservers=`cat "$HOSTLIST"`

if [ "$regionservers" = "localhost" ]; then   <-- This line

  "$bin"/local-regionservers.sh start 1

So bottomline is you *must* have "localhost" in conf/regionservers (no
hostnames or FQDN) and as per HBASE-12263 your "hostname -f"  *should not*
resolve to a localhost. Otherwise you see something like

2014-11-30 12:33:23,230 FATAL [main] regionserver.RSRpcServices: The
hostname of regionserver cannot be set to localhost in a fully-distributed
setup because it won't be reachable. See "Getting Started" for more
information.

2014-11-30 12:33:23,231 ERROR [main] regionserver.HRegionServerCommandLine:
Region server exiting

Set it using DNS or hack the /etc/hosts file.

Thanks,
Bharath



On Mon, Dec 1, 2014 at 11:30 AM, guxiaobo1982 <[email protected]> wrote:

> My environment is CENTOS 6.5 64 bit with Oracle JDK 1.7.0
>
>
>
>
> ------------------ Original ------------------
> From:  "Bharath Vissapragada";<[email protected]>;
> Send time: Sunday, Nov 30, 2014 11:58 PM
> To: "hbase-user"<[email protected]>;
>
> Subject:  Re: port confilct with hadoop 2.5.2 and hbase 0.99.1
>
>
>
> I'm not totally sure whats happening here. I'm able to reproduce this issue
> on my Mac but the same thing when run on a linux host works fine. Strangely
> in the linux host, it picks another port to run the RSRpcServices.
>
> 2014-11-30 04:39:16,267 INFO  [main] regionserver.RSRpcServices:
> regionserver/host-10-16-8-145.openstacklocal/10.16.8.145:16201 server-side
> HConnection retries=350
>
> The only difference between these two setups is that the linux host has a
> proper DNS and in the Mac I did some hacks to the /etc/hosts. Both setups
> use 0.99.1+2.5.2.
>
> On Sun, Nov 30, 2014 at 6:30 AM, 顾小波 <[email protected]> wrote:
>
> > But Bharath said the new master embeds an internal region server, is an
> > external region server still needed on pseudo distribution mode?
> >
> > 发自我的 iPad
> >
> > > 在 2014年11月29日,下午10:45,Ted Yu <[email protected]> 写道:
> > >
> > > Bharath
> >
> >
> >
>
>
> --
> Bharath Vissapragada
> <http://www.cloudera.com>




-- 
Bharath Vissapragada
<http://www.cloudera.com>

Reply via email to