MySQL data is recently needed to be integrated into HBase, using MapReduce to create a job to import MySQL data.
In the process of accessing the data, we found the tools that open source tools Sqoop (relational database and hdfs,hbase,hive, etc.) import each other,
So you're ready to try and see if you can meet the current data transfer requirements.
Sqoop import--connect jdbc:mysql://192.168.100.**/database--username user-p--table Information--hbase-table Information--column-family Info--hbase-row-key market,label--columns market,label,name,py--hbase-create-table-m 1
--hbase-row-key Market,label This command can produce Rowkey in Market_label format
Question 1:
ERROR security. Usergroupinformation:priviledgedactionexception ...
This problem is caused primarily by permissions issues, and the user does not create a folder with permissions under the target path
Sudo-u HDFs Hadoop Fs-mkdir/user/user
Sudo-u HDFs Hadoop Fs-chown user:user/user/user
(The/user folder is the default path if Sqoop does not indicate a file path)
Question 2:
Could not insert row with null value for Row-key column:
This problem may be due to the use of the problem, in columns need to indicate the column Row-key used
Use of Sqoop (Mysql to HBase)