SlideShare a Scribd company logo
How to Connect HBase in Hortonworks SandBox Using SqlWorkbenchJ As
Phoenix GUI Client From Windows
While Iwas testing Apache Phoenix withhbase in Hortonworkssandbox 2.2.0.0-2041, I foundno
Phoenix wasinstalled, soI downloadedand installednewestversionof Phoenix 4.3.1andrun into
some problems, ItriedtobuildPheonix fromsource,buildingwassmoothbutthere were somany
runtime exceptions,mostlylibcompatibilityissues.Atthattime,anew versionof sandbox was
released, Idownloadednewversionof Sandbox 2.2.4.2-2whichcomeswithPhoenix.Phoenix officail
website recommendtouse Squirrel asclient,butSquirrel clientisnotcompatible withPhoenix innew
versionof sandBox,pleasesee https://issues.apache.org/jira/browse/PHOENIX-1613.Hortonworkssaid
the issue will be resolvedinnextrelease.
CertainlyIcouldnotwaittill newSquirrel clientrelease.Afterall,Squirrel justaJDBCclient,there must
be otheralternatives. ItriedSqlWorkbench,which workslike acharmp.Youmay install SqlWorkbench
inSandbox,butthismethodhas serious drawbacks,because UIcomponentusesalotof memory,it
leaveslessmemoryforthe componentstorun, and inmy case, sandbox ishostedin ESXI and I only
have commandlinesaccess i.gconnectviassh,install SqlWorkbenchJinsandbox will notwork.
I couldnot finddocumenttosetupSql clientinwindowsandinteractwithPhoenix inLinux. Tome itis
crucial to separate GUI clientwithserver,whichmotivatesme towrite thisarticle. Ittookme some
time to finda workable solution, mostlybecauseIwasnot aware there issecondaryip insandbox,
untill IinstalledtcpdumpandwiresharkandIwentthroughstepsto rule outit wasnot because of
firewall thatcausedconnectionreset. Ihope myarticle will be helpful toothers.
Software todownload :
downloadHortonworkssandbox 2.2.4, http://hortonworks.com/products/hortonworks-sandbox/
downloadwinutils.exe, http://public-repo-1.hortonworks.com/hdp-win-alpha/winutils.exe
downloadSqlWorkbenchJ, http://www.sql-workbench.net/downloads.html
downloadhadoop-common-2.6.0jar, http://mvnrepository.com/artifact/org.apache.hadoop/hadoop-
common/2.6.0
Setup
Extract SqlWorkbenchJtoatarget directory
Put winutil.exetoa directory andchange sqlworkbench.cmdtopointto the directory
Copy phoenix-4.2.0.2.2.4.2-2-client.jartoSqlworkbenchJinstall directory
Copy hadoop-common-2.6.0toSqlWorkbenchinstall directory
Example:
Copy winutil.exeto C:UsersmxuDownloadsFake_Hadoopbin
Add–Dhadoop.home.dirin sqlworkbench.cmdfile
:gui
start "SQL Workbench/J" "%JAVA_BINPATH%javaw.exe"^
-Xmx512m ^
-Dvisualvm.display.name=SQLWorkbench ^
-Dsun.awt.keepWorkingSetOnMinimize=true ^
-Dsun.java2d.dpiaware=true ^
-Dsun.java2d.noddraw=true ^
-Dhadoop.home.dir=C:UsersmxuDownloadsFake_Hadoop ^
-jar %wbdir%sqlworkbench.jar %*
goto :eof
Add sandbox ip(s) to hosts file
If vm is not hosted in local PC, check for secondary IP, see command below and add secondary in
hosts file
[root@sandbox mxu]# ip addr list dev eth0
Configure SqlWorkbenchJ
Add phoenix driver
Click file -> Manage Driver and add phoenix driver
Create new connection profile
Click File ->Connect Window -> Create a new connection profile
Selectthe Phoenixdriveryoujustcreatedandfillinyourusername andpasswordtologinsandbox.
Click OK, it will start to connect to Hbase.
To start the application, double click SqlWorkbenchJ64.exe
Note:Inmy testing, put either primary or secondary ip in connection URL, connection works fine.
My Windows version: Windows 7 professional service pack 1
References:
https://github.com/spring-projects/spring-hadoop/wiki/Using-a-Windows-client-together-with-a-
Linux-cluster
http://phoenix.apache.org/installation.html

More Related Content

What's hot

6 Years of Docker: The Good, the Bad and Python Packaging at PyCon.DE&PyData ...
6 Years of Docker: The Good, the Bad and Python Packaging at PyCon.DE&PyData ...6 Years of Docker: The Good, the Bad and Python Packaging at PyCon.DE&PyData ...
6 Years of Docker: The Good, the Bad and Python Packaging at PyCon.DE&PyData ...
Sebastian Neubauer
 
Savosyuk Stanislav "Docker: Not to Be Confused with a Blue Whale"
Savosyuk Stanislav "Docker: Not to Be Confused with a Blue Whale"Savosyuk Stanislav "Docker: Not to Be Confused with a Blue Whale"
Savosyuk Stanislav "Docker: Not to Be Confused with a Blue Whale"
LogeekNightUkraine
 
Installing and running Postfix within a docker container from the command line
Installing and running Postfix within a docker container from the command lineInstalling and running Postfix within a docker container from the command line
Installing and running Postfix within a docker container from the command line
dotCloud
 
PHP development with Docker
PHP development with DockerPHP development with Docker
PHP development with Docker
Yosh de Vos
 
WinOps 2017 - Docker on Windows, the Beginner's Guide
WinOps 2017 - Docker on Windows, the Beginner's GuideWinOps 2017 - Docker on Windows, the Beginner's Guide
WinOps 2017 - Docker on Windows, the Beginner's Guide
Elton Stoneman
 
Dockerize Me: Distributed PHP applications with Symfony, Docker, Consul and A...
Dockerize Me: Distributed PHP applications with Symfony, Docker, Consul and A...Dockerize Me: Distributed PHP applications with Symfony, Docker, Consul and A...
Dockerize Me: Distributed PHP applications with Symfony, Docker, Consul and A...
Alexey Petrov
 
DevOps: Docker Workshop
DevOps: Docker WorkshopDevOps: Docker Workshop
DevOps: Docker Workshop
Joonas Hämäläinen
 
Dockerize your Symfony application - Symfony Live NYC 2014
Dockerize your Symfony application - Symfony Live NYC 2014Dockerize your Symfony application - Symfony Live NYC 2014
Dockerize your Symfony application - Symfony Live NYC 2014
André Rømcke
 
Dockerfish-Tutorial
Dockerfish-TutorialDockerfish-Tutorial
Dockerfish-Tutorial
Brian Hood
 
Dockerizing Symfony Applications - Symfony Live Berlin 2014
Dockerizing Symfony Applications - Symfony Live Berlin 2014Dockerizing Symfony Applications - Symfony Live Berlin 2014
Dockerizing Symfony Applications - Symfony Live Berlin 2014
D
 
Docker for Java developers at JavaLand
Docker for Java developers at JavaLandDocker for Java developers at JavaLand
Docker for Java developers at JavaLand
Johan Janssen
 
Docker at Spotify
Docker at SpotifyDocker at Spotify
Docker at Spotify
Rohan Singh
 
Dockerizing a Symfony2 application
Dockerizing a Symfony2 applicationDockerizing a Symfony2 application
Dockerizing a Symfony2 application
Roman Rodomansky
 
Docker Containers Orchestration
Docker Containers OrchestrationDocker Containers Orchestration
Docker Containers Orchestration
Dmitry Fedorov
 
PHP on Heroku: Deploying and Scaling Apps in the Cloud
PHP on Heroku: Deploying and Scaling Apps in the CloudPHP on Heroku: Deploying and Scaling Apps in the Cloud
PHP on Heroku: Deploying and Scaling Apps in the Cloud
Salesforce Developers
 
Conan a C/C++ Package Manager
Conan a C/C++ Package ManagerConan a C/C++ Package Manager
Conan a C/C++ Package Manager
Uilian Ries
 
Setting up the fabric v 0.6 in hyperledger
Setting up the fabric v 0.6 in hyperledgerSetting up the fabric v 0.6 in hyperledger
Setting up the fabric v 0.6 in hyperledger
kesavan N B
 
12 Composer #burningkeyboards
12 Composer #burningkeyboards12 Composer #burningkeyboards
12 Composer #burningkeyboards
Denis Ristic
 
Refresh hilo 20150210 Vagrant
Refresh hilo 20150210 VagrantRefresh hilo 20150210 Vagrant
Refresh hilo 20150210 Vagrant
Jason Kalawe
 

What's hot (19)

6 Years of Docker: The Good, the Bad and Python Packaging at PyCon.DE&PyData ...
6 Years of Docker: The Good, the Bad and Python Packaging at PyCon.DE&PyData ...6 Years of Docker: The Good, the Bad and Python Packaging at PyCon.DE&PyData ...
6 Years of Docker: The Good, the Bad and Python Packaging at PyCon.DE&PyData ...
 
Savosyuk Stanislav "Docker: Not to Be Confused with a Blue Whale"
Savosyuk Stanislav "Docker: Not to Be Confused with a Blue Whale"Savosyuk Stanislav "Docker: Not to Be Confused with a Blue Whale"
Savosyuk Stanislav "Docker: Not to Be Confused with a Blue Whale"
 
Installing and running Postfix within a docker container from the command line
Installing and running Postfix within a docker container from the command lineInstalling and running Postfix within a docker container from the command line
Installing and running Postfix within a docker container from the command line
 
PHP development with Docker
PHP development with DockerPHP development with Docker
PHP development with Docker
 
WinOps 2017 - Docker on Windows, the Beginner's Guide
WinOps 2017 - Docker on Windows, the Beginner's GuideWinOps 2017 - Docker on Windows, the Beginner's Guide
WinOps 2017 - Docker on Windows, the Beginner's Guide
 
Dockerize Me: Distributed PHP applications with Symfony, Docker, Consul and A...
Dockerize Me: Distributed PHP applications with Symfony, Docker, Consul and A...Dockerize Me: Distributed PHP applications with Symfony, Docker, Consul and A...
Dockerize Me: Distributed PHP applications with Symfony, Docker, Consul and A...
 
DevOps: Docker Workshop
DevOps: Docker WorkshopDevOps: Docker Workshop
DevOps: Docker Workshop
 
Dockerize your Symfony application - Symfony Live NYC 2014
Dockerize your Symfony application - Symfony Live NYC 2014Dockerize your Symfony application - Symfony Live NYC 2014
Dockerize your Symfony application - Symfony Live NYC 2014
 
Dockerfish-Tutorial
Dockerfish-TutorialDockerfish-Tutorial
Dockerfish-Tutorial
 
Dockerizing Symfony Applications - Symfony Live Berlin 2014
Dockerizing Symfony Applications - Symfony Live Berlin 2014Dockerizing Symfony Applications - Symfony Live Berlin 2014
Dockerizing Symfony Applications - Symfony Live Berlin 2014
 
Docker for Java developers at JavaLand
Docker for Java developers at JavaLandDocker for Java developers at JavaLand
Docker for Java developers at JavaLand
 
Docker at Spotify
Docker at SpotifyDocker at Spotify
Docker at Spotify
 
Dockerizing a Symfony2 application
Dockerizing a Symfony2 applicationDockerizing a Symfony2 application
Dockerizing a Symfony2 application
 
Docker Containers Orchestration
Docker Containers OrchestrationDocker Containers Orchestration
Docker Containers Orchestration
 
PHP on Heroku: Deploying and Scaling Apps in the Cloud
PHP on Heroku: Deploying and Scaling Apps in the CloudPHP on Heroku: Deploying and Scaling Apps in the Cloud
PHP on Heroku: Deploying and Scaling Apps in the Cloud
 
Conan a C/C++ Package Manager
Conan a C/C++ Package ManagerConan a C/C++ Package Manager
Conan a C/C++ Package Manager
 
Setting up the fabric v 0.6 in hyperledger
Setting up the fabric v 0.6 in hyperledgerSetting up the fabric v 0.6 in hyperledger
Setting up the fabric v 0.6 in hyperledger
 
12 Composer #burningkeyboards
12 Composer #burningkeyboards12 Composer #burningkeyboards
12 Composer #burningkeyboards
 
Refresh hilo 20150210 Vagrant
Refresh hilo 20150210 VagrantRefresh hilo 20150210 Vagrant
Refresh hilo 20150210 Vagrant
 

Similar to How to Connect HBase in Hortonworks SandBox/Cluster using SqlWorkbenchJ as Phoenix Client from Windows

How to automate elixir phoenix deployment with distillery and edeliver on ubu...
How to automate elixir phoenix deployment with distillery and edeliver on ubu...How to automate elixir phoenix deployment with distillery and edeliver on ubu...
How to automate elixir phoenix deployment with distillery and edeliver on ubu...
VasiliyPodnebesniy
 
當專案漸趕,當遷移也不再那麼難 (Ship Your Projects with Docker EcoSystem)
當專案漸趕,當遷移也不再那麼難 (Ship Your Projects with Docker EcoSystem)當專案漸趕,當遷移也不再那麼難 (Ship Your Projects with Docker EcoSystem)
當專案漸趕,當遷移也不再那麼難 (Ship Your Projects with Docker EcoSystem)
Ruoshi Ling
 
JavaCro'15 - Conquer the Internet of Things with Java and Docker - Johan Jans...
JavaCro'15 - Conquer the Internet of Things with Java and Docker - Johan Jans...JavaCro'15 - Conquer the Internet of Things with Java and Docker - Johan Jans...
JavaCro'15 - Conquer the Internet of Things with Java and Docker - Johan Jans...
HUJAK - Hrvatska udruga Java korisnika / Croatian Java User Association
 
Intro- Docker Native for OSX and Windows
Intro- Docker Native for OSX and WindowsIntro- Docker Native for OSX and Windows
Intro- Docker Native for OSX and Windows
Thomas Chacko
 
Docker
DockerDocker
Docker
Brian Hogan
 
Virtual boxen
Virtual boxenVirtual boxen
Virtual boxen
Ngo Huu Thinh
 
Aloofix
AloofixAloofix
Aloofix
Kevin Johnson
 
CocoaPods.pptx
CocoaPods.pptxCocoaPods.pptx
CocoaPods.pptx
Nicole and Yoonseo
 
Phoenix 1.3 Umbrella App deployment via Distillery-Docker-Docker_Compose
Phoenix 1.3 Umbrella App deployment via Distillery-Docker-Docker_ComposePhoenix 1.3 Umbrella App deployment via Distillery-Docker-Docker_Compose
Phoenix 1.3 Umbrella App deployment via Distillery-Docker-Docker_Compose
Yeong Sheng Tan
 
OSCON: Advanced Docker developer workflows on Mac OS and Windows
OSCON: Advanced Docker developer workflows on Mac OS and WindowsOSCON: Advanced Docker developer workflows on Mac OS and Windows
OSCON: Advanced Docker developer workflows on Mac OS and Windows
Docker, Inc.
 
Advanced Docker Developer Workflows on MacOS X and Windows
Advanced Docker Developer Workflows on MacOS X and WindowsAdvanced Docker Developer Workflows on MacOS X and Windows
Advanced Docker Developer Workflows on MacOS X and Windows
Anil Madhavapeddy
 
Agile Brown Bag - Vagrant & Docker: Introduction
Agile Brown Bag - Vagrant & Docker: IntroductionAgile Brown Bag - Vagrant & Docker: Introduction
Agile Brown Bag - Vagrant & Docker: Introduction
Agile Partner S.A.
 
Node.js, Vagrant, Chef, and Mathoid @ Benetech
Node.js, Vagrant, Chef, and Mathoid @ BenetechNode.js, Vagrant, Chef, and Mathoid @ Benetech
Node.js, Vagrant, Chef, and Mathoid @ Benetech
Christopher Bumgardner
 
CloudFoundry@home
CloudFoundry@homeCloudFoundry@home
CloudFoundry@home
Yohei Sasaki
 
ContainerDays Boston 2016: "Docker For the Developer" (Borja Burgos)
ContainerDays Boston 2016: "Docker For the Developer" (Borja Burgos)ContainerDays Boston 2016: "Docker For the Developer" (Borja Burgos)
ContainerDays Boston 2016: "Docker For the Developer" (Borja Burgos)
DynamicInfraDays
 

Similar to How to Connect HBase in Hortonworks SandBox/Cluster using SqlWorkbenchJ as Phoenix Client from Windows (15)

How to automate elixir phoenix deployment with distillery and edeliver on ubu...
How to automate elixir phoenix deployment with distillery and edeliver on ubu...How to automate elixir phoenix deployment with distillery and edeliver on ubu...
How to automate elixir phoenix deployment with distillery and edeliver on ubu...
 
當專案漸趕,當遷移也不再那麼難 (Ship Your Projects with Docker EcoSystem)
當專案漸趕,當遷移也不再那麼難 (Ship Your Projects with Docker EcoSystem)當專案漸趕,當遷移也不再那麼難 (Ship Your Projects with Docker EcoSystem)
當專案漸趕,當遷移也不再那麼難 (Ship Your Projects with Docker EcoSystem)
 
JavaCro'15 - Conquer the Internet of Things with Java and Docker - Johan Jans...
JavaCro'15 - Conquer the Internet of Things with Java and Docker - Johan Jans...JavaCro'15 - Conquer the Internet of Things with Java and Docker - Johan Jans...
JavaCro'15 - Conquer the Internet of Things with Java and Docker - Johan Jans...
 
Intro- Docker Native for OSX and Windows
Intro- Docker Native for OSX and WindowsIntro- Docker Native for OSX and Windows
Intro- Docker Native for OSX and Windows
 
Docker
DockerDocker
Docker
 
Virtual boxen
Virtual boxenVirtual boxen
Virtual boxen
 
Aloofix
AloofixAloofix
Aloofix
 
CocoaPods.pptx
CocoaPods.pptxCocoaPods.pptx
CocoaPods.pptx
 
Phoenix 1.3 Umbrella App deployment via Distillery-Docker-Docker_Compose
Phoenix 1.3 Umbrella App deployment via Distillery-Docker-Docker_ComposePhoenix 1.3 Umbrella App deployment via Distillery-Docker-Docker_Compose
Phoenix 1.3 Umbrella App deployment via Distillery-Docker-Docker_Compose
 
OSCON: Advanced Docker developer workflows on Mac OS and Windows
OSCON: Advanced Docker developer workflows on Mac OS and WindowsOSCON: Advanced Docker developer workflows on Mac OS and Windows
OSCON: Advanced Docker developer workflows on Mac OS and Windows
 
Advanced Docker Developer Workflows on MacOS X and Windows
Advanced Docker Developer Workflows on MacOS X and WindowsAdvanced Docker Developer Workflows on MacOS X and Windows
Advanced Docker Developer Workflows on MacOS X and Windows
 
Agile Brown Bag - Vagrant & Docker: Introduction
Agile Brown Bag - Vagrant & Docker: IntroductionAgile Brown Bag - Vagrant & Docker: Introduction
Agile Brown Bag - Vagrant & Docker: Introduction
 
Node.js, Vagrant, Chef, and Mathoid @ Benetech
Node.js, Vagrant, Chef, and Mathoid @ BenetechNode.js, Vagrant, Chef, and Mathoid @ Benetech
Node.js, Vagrant, Chef, and Mathoid @ Benetech
 
CloudFoundry@home
CloudFoundry@homeCloudFoundry@home
CloudFoundry@home
 
ContainerDays Boston 2016: "Docker For the Developer" (Borja Burgos)
ContainerDays Boston 2016: "Docker For the Developer" (Borja Burgos)ContainerDays Boston 2016: "Docker For the Developer" (Borja Burgos)
ContainerDays Boston 2016: "Docker For the Developer" (Borja Burgos)
 

How to Connect HBase in Hortonworks SandBox/Cluster using SqlWorkbenchJ as Phoenix Client from Windows

  • 1. How to Connect HBase in Hortonworks SandBox Using SqlWorkbenchJ As Phoenix GUI Client From Windows While Iwas testing Apache Phoenix withhbase in Hortonworkssandbox 2.2.0.0-2041, I foundno Phoenix wasinstalled, soI downloadedand installednewestversionof Phoenix 4.3.1andrun into some problems, ItriedtobuildPheonix fromsource,buildingwassmoothbutthere were somany runtime exceptions,mostlylibcompatibilityissues.Atthattime,anew versionof sandbox was released, Idownloadednewversionof Sandbox 2.2.4.2-2whichcomeswithPhoenix.Phoenix officail website recommendtouse Squirrel asclient,butSquirrel clientisnotcompatible withPhoenix innew versionof sandBox,pleasesee https://issues.apache.org/jira/browse/PHOENIX-1613.Hortonworkssaid the issue will be resolvedinnextrelease. CertainlyIcouldnotwaittill newSquirrel clientrelease.Afterall,Squirrel justaJDBCclient,there must be otheralternatives. ItriedSqlWorkbench,which workslike acharmp.Youmay install SqlWorkbench inSandbox,butthismethodhas serious drawbacks,because UIcomponentusesalotof memory,it leaveslessmemoryforthe componentstorun, and inmy case, sandbox ishostedin ESXI and I only have commandlinesaccess i.gconnectviassh,install SqlWorkbenchJinsandbox will notwork. I couldnot finddocumenttosetupSql clientinwindowsandinteractwithPhoenix inLinux. Tome itis crucial to separate GUI clientwithserver,whichmotivatesme towrite thisarticle. Ittookme some time to finda workable solution, mostlybecauseIwasnot aware there issecondaryip insandbox, untill IinstalledtcpdumpandwiresharkandIwentthroughstepsto rule outit wasnot because of firewall thatcausedconnectionreset. Ihope myarticle will be helpful toothers. Software todownload : downloadHortonworkssandbox 2.2.4, http://hortonworks.com/products/hortonworks-sandbox/ downloadwinutils.exe, http://public-repo-1.hortonworks.com/hdp-win-alpha/winutils.exe downloadSqlWorkbenchJ, http://www.sql-workbench.net/downloads.html downloadhadoop-common-2.6.0jar, http://mvnrepository.com/artifact/org.apache.hadoop/hadoop- common/2.6.0 Setup Extract SqlWorkbenchJtoatarget directory Put winutil.exetoa directory andchange sqlworkbench.cmdtopointto the directory Copy phoenix-4.2.0.2.2.4.2-2-client.jartoSqlworkbenchJinstall directory Copy hadoop-common-2.6.0toSqlWorkbenchinstall directory Example: Copy winutil.exeto C:UsersmxuDownloadsFake_Hadoopbin Add–Dhadoop.home.dirin sqlworkbench.cmdfile :gui
  • 2. start "SQL Workbench/J" "%JAVA_BINPATH%javaw.exe"^ -Xmx512m ^ -Dvisualvm.display.name=SQLWorkbench ^ -Dsun.awt.keepWorkingSetOnMinimize=true ^ -Dsun.java2d.dpiaware=true ^ -Dsun.java2d.noddraw=true ^ -Dhadoop.home.dir=C:UsersmxuDownloadsFake_Hadoop ^ -jar %wbdir%sqlworkbench.jar %* goto :eof Add sandbox ip(s) to hosts file If vm is not hosted in local PC, check for secondary IP, see command below and add secondary in hosts file [root@sandbox mxu]# ip addr list dev eth0 Configure SqlWorkbenchJ Add phoenix driver Click file -> Manage Driver and add phoenix driver
  • 3. Create new connection profile Click File ->Connect Window -> Create a new connection profile Selectthe Phoenixdriveryoujustcreatedandfillinyourusername andpasswordtologinsandbox. Click OK, it will start to connect to Hbase. To start the application, double click SqlWorkbenchJ64.exe Note:Inmy testing, put either primary or secondary ip in connection URL, connection works fine. My Windows version: Windows 7 professional service pack 1 References: https://github.com/spring-projects/spring-hadoop/wiki/Using-a-Windows-client-together-with-a- Linux-cluster http://phoenix.apache.org/installation.html