sql—从文件在hbase中大容量插入

lmvvr0a8  于 2021-06-03  发布在  Hadoop
关注(0)|答案(0)|浏览(241)

我试图在一个表中插入许多行(我的目标是插入10亿个虚拟行)。我就是这么做的:
我将与插入内容相对应的10亿sql行写入到一个文件中。 ./hbase shell < insert.sql 前几次插入很顺利,但很快我就遇到了这个错误

put 'test', 'row19115', 'cf:a', '19115'

ERROR: java.lang.OutOfMemoryError: unable to create new native thread

Here is some help for this command:
Put a cell 'value' at specified table/row/column and optionally
timestamp coordinates.  To put a cell value into table 't1' at
row 'r1' under column 'c1' marked with the time 'ts1', do:

  hbase> put 't1', 'r1', 'c1', 'value', ts1

如何纠正这个错误/有更好的方法吗?
另外,是否有其他方法来执行插入而不是每次都将其写入文件?

暂无答案!

目前还没有任何答案,快来回答吧!

相关问题