Sqoop导入到Hbase

1
2
3
4
5
6
7
8
9
10
11
sqoop import \
--connect jdbc:mysql://master:3306/sqoop_db \
--username root \
--password 123456 \
--table city \
--hbase-create-table \
--hbase-table hkjcpdd:city \
--column-family cf \
--hbase-row-key id

# --hbase-row-key:要求mysql表必须有主见,将主键作为rowkey,表示一行