一条龙,应该玩的,都玩起来~
参考URL:
https://www.jianshu.com/p/c971d5c21633
一,下载并运行hbase的docker容器
不开端口
docker run -d --name hbase -P harisekhon/hbase:1.3
开很多端口
docker run -d --name hbase -p 2181:2181 -p 8080:8080 -p 8085:8085 -p 9090:9090 -p 9095:9095 -p 16000:16000 -p 16010:16010 -p 16201:16201 -p 16301:16301 harisekhon/hbase:1.3
二,进入容器实践
docker exec -it hbase /bin/bash
hbase shell
list
create 'student','info'
put 'student','1001','info:sex','male'
put 'student','1001','info:age','18'
put 'student','1002','info:name', 'Janna'
put 'student','1002','info:sex','female'
put 'student','1002','info:age','20'
scan 'student'
scan 'student', {STARTROW => '1001', STOPROW => '1002'}
describe 'student'
![](https://img.haomeiwen.com/i23118846/682b51db868c0c28.png)
![](https://img.haomeiwen.com/i23118846/b044786e6286d80a.png)
三,WEB上也能看到相关数据表
![](https://img.haomeiwen.com/i23118846/255cf8bfff98da83.png)
网友评论