sqoop版本:sqoop-1.4.6-cdh5.14.2
资源路径:百度网盘 请输入提取码
提取码:zzzz
1、将软件安装包拷贝到 /opt 目录下
2、创建sqoop安装目录
命令:
mkdir /opt/soft/sqoop146
3、将安装包解压到安装目录
命令:
tar -zxvf sqoop-1.4.6-cdh5.14.2.tar.gz -C /opt/soft/sqoop146 --scrip-components 1
4、移动到sqoop安装目录下的conf目录
命令:
cd /opt/soft/sqoop146/conf
5、将文件 sqoop-env-template.sh 拷贝一份,改名为 sqoop-env.sh
命令:
cp sqoop-env-template.sh sqoop-env.sh
6、编辑 sqoop-env.sh 文件,添加如下内容
export HADOOP_COMMON_HOME=/opt/soft/hadoop260
export HADOOP_MAPRED_HOME=/opt/soft/hadoop260
export HBASE_HOME=/opt/soft/hbase120
export HIVE_HOME=/opt/soft/hive110
export ZOOCFGDIR=/opt/soft/zk345/conf
7、将sqoop需要连接数据库的jar包拷贝到安装目录的lib目录下
命令:
cp /opt/soft/hadoop260/share/hadoop/common/hadoop-common-2.6.0-cdh5.14.2.jar /opt/soft/sqoop146/lib/
cp /opt/soft/hadoop260/share/hadoop/hdfs/hadoop-hdfs-2.6.0-cdh5.14.2.jar /opt/soft/sqoop146/lib/
cp /opt/soft/hadoop260/share/hadoop/mapreduce/hadoop-mapreduce-client-core-2.6.0-cdh5.14.2.jar /opt/soft/sqoop146/lib/
cp /opt/soft/hive110/lib/hive-jdbc-1.1.0-cdh5.14.2.jar /opt/soft/sqoop146/lib/
cp /opt/soft/hive110/lib/hive-jdbc-1.1.0-cdh5.14.2-standalone.jar /opt/soft/sqoop146/lib/