<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>how to install HBase on Ubuntu Archives - Linux Windows and android Tutorials</title>
	<atom:link href="https://www.osradar.com/tag/how-to-install-hbase-on-ubuntu/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.osradar.com</link>
	<description>tutorials and news and Seurity</description>
	<lastBuildDate>Mon, 06 Jan 2020 12:41:34 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=5.8.12</generator>
	<item>
		<title>How To Install HBase on Ubuntu 18.04</title>
		<link>https://www.osradar.com/how-to-install-hbase-on-ubuntu-18-04/</link>
					<comments>https://www.osradar.com/how-to-install-hbase-on-ubuntu-18-04/#respond</comments>
		
		<dc:creator><![CDATA[sabi]]></dc:creator>
		<pubDate>Mon, 06 Jan 2020 12:41:32 +0000</pubDate>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Servers]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[Hbase installation with Hadoop]]></category>
		<category><![CDATA[how to install HBase on Ubuntu]]></category>
		<category><![CDATA[install HBase on Ubuntu]]></category>
		<guid isPermaLink="false">https://www.osradar.com/?p=17342</guid>

					<description><![CDATA[<p>Today we will learn that how we can Install HBase on our Ubuntu 18.04 system. HBase has two modes. Standalone Mode Pseudo-Distributed Mode Let&#8217;s move towards the Installation Step 1: Download &#38; Install HBase Download the stable release of HBase for production use. VER="1.4.12"wget http://apache.mirror.gtcomm.net/hbase/stable/hbase-$VER-bin.tar.gz Extract the downloaded archive. tar xvf hbase-$VER-bin.tar.gz Now, use the [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://www.osradar.com/how-to-install-hbase-on-ubuntu-18-04/">How To Install HBase on Ubuntu 18.04</a> appeared first on <a rel="nofollow" href="https://www.osradar.com">Linux  Windows and android  Tutorials</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p>Today we will learn that how we can Install HBase on our Ubuntu 18.04 system. HBase has two modes.</p>



<ul><li><strong>Standalone Mode</strong></li><li><strong>Pseudo-Distributed Mode</strong></li></ul>



<p>Let&#8217;s move towards the Installation</p>



<h3><strong>Step 1: Download &amp; Install HBase</strong></h3>



<p>Download <a href="http://apache.mirror.gtcomm.net/hbase/stable/">the stable release</a> of HBase for production use.</p>



<pre class="wp-block-verse">VER="1.4.12"<br>wget http://apache.mirror.gtcomm.net/hbase/stable/hbase-$VER-bin.tar.gz</pre>



<p>Extract the downloaded archive.</p>



<pre class="wp-block-verse">tar xvf hbase-$VER-bin.tar.gz</pre>



<p>Now, use the given command to move file to <strong>/usr/local/HBase/</strong> directory.</p>



<pre class="wp-block-verse">sudo mv hbase-$VER/ /usr/local/HBase/</pre>



<p>Update your<strong> $PATH</strong> value</p>



<pre class="wp-block-verse">cat &lt;&lt;EOF | sudo tee /etc/profile.d/hadoop_java.sh<br>export JAVA_HOME=$(dirname $(dirname $(readlink $(readlink $(which javac)))))<br>export HADOOP_HOME=/usr/local/hadoop<br>export HADOOP_HDFS_HOME=$HADOOP_HOME<br>export HADOOP_MAPRED_HOME=$HADOOP_HOME<br>export YARN_HOME=$HADOOP_HOME<br>export HADOOP_COMMON_HOME=$HADOOP_HOME<br>export HADOOP_COMMON_LIB_NATIVE_DIR=$HADOOP_HOME/lib/native<br>export HBASE_HOME=/usr/local/HBase<br>export PATH=\$PATH:\$JAVA_HOME/bin:\$HADOOP_HOME/bin:\$HADOOP_HOME/sbin:\$HBASE_HOME/bin<br>EOF</pre>



<p>Update shell environment values.</p>



<pre class="wp-block-verse">$ source /etc/profile.d/hadoop_java.sh<br> $ echo $HBASE_HOME<br> /usr/local/HBase</pre>



<p>Edit J<strong>AVA_HOM</strong>E in shell script <strong>hbase-env.sh</strong></p>



<pre class="wp-block-verse">$ sudo vim /usr/local/HBase/conf/hbase-env.sh<br> Set JAVA_HOME - Line 27<br> export JAVA_HOME=/usr/lib/jvm/java-8-oracle</pre>



<h3><strong>Step 2: Configure HBase</strong></h3>



<p>You can find out all config files of HBase under <strong>/usr/local/HBase/conf</strong> .</p>



<p>We will do the configurations like we did for <a href="https://www.osradar.com/?p=17201">Hadoop.</a></p>



<h4><strong>hbase-site.xml</strong></h4>



<p>Set data directory to an appropriate location on this file</p>



<h3><strong>Option 1: Install HBase in Standalone Mode (Not Recommended)</strong></h3>



<p>All daemon will run in one jvm process so this is not recommended.</p>



<p>Make HBase root directory.</p>



<pre class="wp-block-verse">sudo mkdir -p /hadoop/HBase/HFiles<br>sudo mkdir -p /hadoop/zookeeper<br>sudo chown -R hadoop:hadoop /hadoop/</pre>



<p>Edit the file.</p>



<pre class="wp-block-verse">sudo nano /usr/local/HBase/conf/hbase-site.xml</pre>



<p>Do the same configuration</p>



<pre class="wp-block-verse">&lt;configuration&gt;<br>&lt;property&gt;<br>         &lt;name&gt;hbase.rootdir&lt;/name&gt;<br>       &lt;value&gt;file:/hadoop/HBase/HFiles&lt;/value&gt;<br>&lt;/property&gt;<br><br>&lt;property&gt;    <br>       &lt;name&gt;hbase.zookeeper.property.dataDir&lt;/name&gt;<br>       &lt;value&gt;/hadoop/zookeeper&lt;/value&gt;<br>&lt;/property&gt;<br>&lt;/configuration&gt;<br>  </pre>



<p>Unless you configure the <strong>hbase.rootdir</strong> property, your data is stored in <strong>/tmp/</strong></p>



<p>Start HBase</p>



<pre class="wp-block-verse">$ sudo su - hadoop<br>$ start-hbase.sh <br>running master, logging to /usr/local/HBase/logs/hbase-hadoop-master-hbase.out</pre>



<h3><strong>Option 2: Install HBase in Pseudo-Distributed Mode (Recommended)</strong></h3>



<p>Pseudo-Distributed mode runs only on single host but each HBase daemon runs as a separate process.</p>



<p>Set values of HBase according to below to Install it.</p>



<pre class="wp-block-verse">&lt;configuration&gt;<br>&lt;property&gt;<br>       &lt;name&gt;hbase.rootdir&lt;/name&gt;<br>       &lt;value&gt;hdfs://localhost:8030/hbase&lt;/value&gt;<br>&lt;/property&gt;<br><br>    &lt;property&gt;<br>        &lt;name&gt;hbase.zookeeper.property.dataDir&lt;/name&gt;<br>       &lt;value&gt;/hadoop/zookeeper&lt;/value&gt;<br>&lt;/property&gt;<br><br>&lt;property&gt;<br>       &lt;name&gt;hbase.cluster.distributed&lt;/name&gt;<br>      &lt;value&gt;true&lt;/value&gt;<br>      &lt;/property&gt;<br> &lt;configuration&gt;</pre>



<p>Your data will be stored in HDFS in this setup.<br>Create Zookeeper directory by typing</p>



<pre class="wp-block-verse">sudo mkdir -p /hadoop/zookeeper<br>sudo chown -R hadoop:hadoop /hadoop/</pre>



<p>Start HBase by using <strong>start-hbase.sh</strong> script in HBase bin directory.</p>



<pre class="wp-block-verse">$ sudo su - hadoop<br>
$ start-hbase.sh <br>
localhost: running zookeeper, logging to /usr/local/HBase/bin/../logs/hbase-hadoop-zookeeper-hbase.out<br>
running master, logging to /usr/local/HBase/logs/hbase-hadoop-master-hbase.out<br>
: running regionserver, logging to /usr/local/HBase/logs/hbase-hadoop-regionserver-hbase.out</pre>



<p>See the HBase Directory in HDFS</p>



<pre class="wp-block-verse">hadoop fs -ls /hbase</pre>



<h3><strong>Step 3: Managing HMaster &amp; HRegionServer</strong></h3>



<p>HRegion server stores the data into StoreFiles as directed by the HMaster while HMaster server controls the HBase cluster.<br>Both servers can be started &amp; stopped using the scripts <strong>local-master-backup.sh</strong> and <strong>local-regionserver.sh</strong> respectively.</p>



<pre class="wp-block-verse">$ local-master-backup.sh start 2 # Start backup HMaster<br>$ local-regionservers.sh start 3 # Start multiple RegionServers</pre>



<p>HMaster uses two ports (<strong>16000 and 16010</strong> by default). Due to port offset, HMaster uses ports <strong>16002</strong> and <strong>16012</strong></p>



<p>Run the given command to start 3 backup servers using ports <strong>16002/16012 , 16003/16013, 16005/16015</strong></p>



<pre class="wp-block-verse">$ local-master-backup.sh start 2 3 5</pre>



<p>RegionServer requires two ports, default ports are <strong>16020 &amp; 16030.</strong></p>



<p>To start additional RegionServers, running on sequential ports starting at <strong>16022/16032 (base ports 16020/16030 plus 2)</strong></p>



<pre class="wp-block-verse">$ local-regionservers.sh start 2 3 4 5</pre>



<p>In order to stop , just replace the <strong>start</strong> with <strong>stop</strong> parameter. e.g;</p>



<pre class="wp-block-verse">$ local-regionservers.sh stop 5</pre>



<h3><strong>Step 4: Starting HBase Shell</strong></h3>



<p>Hadoop &amp; HBase should be running before you can use HBase shell. Type the following to start services.</p>



<pre class="wp-block-verse">start-all.sh<br>start-hbase.sh</pre>



<p>Then use HBase shell</p>



<pre class="wp-block-verse">hbase shell</pre>



<h3><strong>Stopping HBase</strong></h3>



<pre class="wp-block-verse">stop-hbase.sh</pre>



<p>See our tutorial: <a href="https://www.osradar.com/?p=17201">How To Install Hadoop on Ubuntu 18.04</a></p>



<p>Congratulations! You&#8217;ve finished installing HBase on Ubuntu 18.04. To learn more about Hadoop &amp; HBase visit <a href="https://hadoop.apache.org/docs/current/">Apache Hadoop Documentation</a> &amp; <a href="https://hbase.apache.org/book.html">Apache HBase book</a>.</p>
<p>The post <a rel="nofollow" href="https://www.osradar.com/how-to-install-hbase-on-ubuntu-18-04/">How To Install HBase on Ubuntu 18.04</a> appeared first on <a rel="nofollow" href="https://www.osradar.com">Linux  Windows and android  Tutorials</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.osradar.com/how-to-install-hbase-on-ubuntu-18-04/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
