我安装了DSE并在.bashrc和sqoop-env.sh中设置了路径。 Fisrt我使用命令
运行了dsecd dse/bin
sudo sh dse-env.sh
然后我使用命令
启动了作业跟踪器和任务跟踪器进程~/dse/bin/dse Cassandra -t
我尝试使用命令
将数据库person.empl导入到已创建的键空间comp的空列族emp中~/dse/bin/dse sqoop cql-import --table empl --cassandra-keyspace comp --cassandra-table emp --connect jdbc:mysql://127.0.0.1/person --username root --password root --cassandra-host 127.0.0.1 -m 1
但我收到以下异常
Exception in thread "main" java.lang.NoSuchMethodError: org.jboss.netty.handler.codec.frame.LengthFieldBasedFrameDecoder.<init>(IIIIIZ)V
at com.datastax.driver.core.Frame$DecoderV1.<init>(Frame.java:179)
at com.datastax.driver.core.Frame$Decoder.<clinit>(Frame.java:162)
at com.datastax.driver.core.Connection$PipelineFactory.getPipeline(Connection.java:1029)
at org.jboss.netty.bootstrap.ClientBootstrap.connect(ClientBootstrap.java:212)
at org.jboss.netty.bootstrap.ClientBootstrap.connect(ClientBootstrap.java:188)
at com.datastax.driver.core.Connection.<init>(Connection.java:99)
at com.datastax.driver.core.Connection$Factory.open(Connection.java:573)
at com.datastax.driver.core.ControlConnection.tryConnect(ControlConnection.java:244)
at com.datastax.driver.core.ControlConnection.reconnectInternal(ControlConnection.java:190)
at com.datastax.driver.core.ControlConnection.connect(ControlConnection.java:78)
at com.datastax.driver.core.Cluster$Manager.init(Cluster.java:1230)
at com.datastax.driver.core.Cluster.init(Cluster.java:157)
at com.datastax.driver.core.Cluster.connect(Cluster.java:245)
at com.datastax.bdp.sqoop.SqoopUtil.setCqlImportOptions(SqoopUtil.java:146)
at com.datastax.bdp.sqoop.CqlImportJob.configureOutputFormat(CqlImportJob.java:79)
at org.apache.sqoop.mapreduce.ImportJobBase.runImport(ImportJobBase.java:240)
at com.datastax.bdp.sqoop.SqlManagerAdapter.importTable(SqlManagerAdapter.java:236)
at org.apache.sqoop.tool.ImportTool.importTable(ImportTool.java:497)
at org.apache.sqoop.tool.ImportTool.run(ImportTool.java:601)
at org.apache.sqoop.Sqoop.run(Sqoop.java:143)
at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:65)
at org.apache.sqoop.Sqoop.runSqoop(Sqoop.java:179)
at org.apache.sqoop.Sqoop.runTool(Sqoop.java:218)
at org.apache.sqoop.Sqoop.runTool(Sqoop.java:227)
at org.apache.sqoop.Sqoop.main(Sqoop.java:236)
at com.cloudera.sqoop.Sqoop.main(Sqoop.java:57)
Cassandra / lib中存在的nettyjar版本为4.0.23,而Cassandra / tools / lib中的版本为3.9.0
有人可以帮忙解决这个问题吗?