Includes a fix of the
java.net.UnknownHostExceptioncontainerIderror when a client connecting to Zookeeper.
- Git;
- Docker;
- Docker Compose — included as part of the Docker Desktop for Windows and Mac, for GNU/Linux install using
pip3.
git clone https://github.com/mrauhu/apache-hbase-phoenix
cd apache-hbase-phoenix
Run as Administrator in Command Prompt:
echo 127.0.0.1 hbase >> %WINDIR%\System32\drivers\etc\hostsOn GNU/Linux and macOS the fix applying automatically.
-
Run containers in background:
docker-compose up -d -
Connect using JDBC URI:
127.0.0.1:2181Example of connect using the
sqlline.py:docker-compose exec hbase python /opt/apache-phoenix-5.0.0-HBase-2.0-bin/sqlline.py hbase:2181:/hbaseFor an exit write
!quitthen press Enter. -
Show last 10 log entries for every container and follow log output:
docker-compose logs -f --tail=10Press Ctrl + C to exit.
-
Stop background containers:
docker-compose stop
Running containers in the foreground and follow log output:
docker-compose up
Press Ctrl + C to exit.
Stopping and removing containers (include orphaned) with networks and volumes:
docker-compose down --volumes --remove-orphans
Setup in *.env files:
hadoop.env;hbase-standalone.env.