我是hadoop的新手,并试图在我的Mac OS X上使用sqoop。 我已经使用brew安装了hadoop和sqoop。 hadoop的版本是3.1.2
安装sqoop的位置是:/usr/local/Cellar/sqoop/1.4.6_1/
sqoop-env.sh文件如下所示:
export HADOOP_HOME="/usr/local/opt/hadoop"
export HBASE_HOME="/usr/local"
export HIVE_HOME="/usr/local"
export HCAT_HOME="/usr/local"
export ZOOCFGDIR="/usr/local/etc/zookeeper"
export ZOOKEEPER_HOME="/usr/local/opt/zookeeper"
我已经检查了所有位置,它们是正确的。以下是ls -l /usr/local/bin/ | grep hadoop
lrwxr-xr-x 1 adityad admin 45 Apr 16 18:17 container-executor -> ../Cellar/hadoop/3.1.2/bin/container-executor
lrwxr-xr-x 1 adityad admin 33 Apr 16 18:17 hadoop -> ../Cellar/hadoop/3.1.2/bin/hadoop
lrwxr-xr-x 1 adityad admin 31 Apr 16 18:17 hdfs -> ../Cellar/hadoop/3.1.2/bin/hdfs
lrwxr-xr-x 1 adityad admin 33 Apr 16 18:17 mapred -> ../Cellar/hadoop/3.1.2/bin/mapred
lrwxr-xr-x 1 adityad admin 50 Apr 16 18:17 test-container-executor -> ../Cellar/hadoop/3.1.2/bin/test-container-executor
lrwxr-xr-x 1 adityad admin 31 Apr 16 18:17 yarn -> ../Cellar/hadoop/3.1.2/bin/yarn
当我尝试运行任何sqoop
命令时,什么都没有发生。
我尝试运行:
sqoop-list-tables --connect jdbc:postgresql://<host>:5432/<DB> --username <user> --password <password>
我刚得到以下警告:
Warning: /usr/local/lib/sqoop/../hbase does not exist! HBase imports will fail.
Please set $HBASE_HOME to the root of your HBase installation.
Warning: /usr/local/lib/sqoop/../hcatalog does not exist! HCatalog jobs will fail.
Please set $HCAT_HOME to the root of your HCatalog installation.
Warning: /usr/local/lib/sqoop/../accumulo does not exist! Accumulo imports will fail.
Please set $ACCUMULO_HOME to the root of your Accumulo installation.
Warning: /usr/local/lib/sqoop/../zookeeper does not exist! Accumulo imports will fail.
Please set $ZOOKEEPER_HOME to the root of your Zookeeper installation.
即使sqoop-version
命令也没有给出以上警告。