我试图将Mahout与外部数据源集成。我正在关注Apache Mahout Cookbook本书。
我已经配置了Hadoop 2.4,MySQL服务器,我已经将一个虚拟数据库导入mysql。
我按照本书中的步骤安装了Apache Sqoop,并在Sqoop库中下载并部署了mysql-connector-java-5.1.30.jar(sqoop / lib)
我用ant命令构建了sqoop:
ant mvn-install
构建顺利。
我尝试使用以下命令从mysql导入数据,如本书所述:
sqoop import-all-tables --connect jdbc:mysql/localohost/bbdatabank --username root -P --verbose
但它没有跟随错误:
Warning: /usr/lib/hbase does not exist! HBase imports will fail.
Please set $HBASE_HOME to the root of your HBase installation.
Warning: /usr/lib/hcatalog does not exist! HCatalog jobs will fail.
Please set $HCAT_HOME to the root of your HCatalog installation.
14/05/05 14:19:29 DEBUG tool.BaseSqoopTool: Enabled debug logging.
Enter password:
14/05/05 14:19:30 DEBUG sqoop.ConnFactory: Loaded manager factory: com.cloudera.sqoop.manager.DefaultManagerFactory
14/05/05 14:19:30 DEBUG sqoop.ConnFactory: Trying ManagerFactory: com.cloudera.sqoop.manager.DefaultManagerFactory
14/05/05 14:19:30 DEBUG manager.DefaultManagerFactory: Trying with scheme: jdbc
14/05/05 14:19:30 ERROR tool.BaseSqoopTool: Got error creating database manager:
java.io.IOException: No manager for connect string: jdbc:mysql/localohost/bbdatabank
at org.apache.sqoop.ConnFactory.getManager(ConnFactory.java:185)
at org.apache.sqoop.tool.BaseSqoopTool.init(BaseSqoopTool.java:225)
at org.apache.sqoop.tool.ImportTool.init(ImportTool.java:84)
at org.apache.sqoop.tool.ImportAllTablesTool.run(ImportAllTablesTool.java:82)
at org.apache.sqoop.Sqoop.run(Sqoop.java:145)
at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:70)
at org.apache.sqoop.Sqoop.runSqoop(Sqoop.java:181)
at org.apache.sqoop.Sqoop.runTool(Sqoop.java:220)
at org.apache.sqoop.Sqoop.runTool(Sqoop.java:229)
at org.apache.sqoop.Sqoop.main(Sqoop.java:238)
有人可以帮我找到我失踪的东西吗?为什么会产生此错误?如何解决?
PS:我还没有安装HBase,也没有安装HCatalog因为这本书说我不需要它。
答案 0 :(得分:4)
看起来您的jdbc网址不正确,应该是
jdbc:mysql://localhost/bbdatabank