Article Directory
1. Sqoop installation and configuration
1. Install the software
1. Upload software
2. Decompression software
·解压到/opt/module文件夹下:
tar -zxvf sqoop-1.4.7.bin__hadoop-2.6.0.tar.gz -C /opt/module
·重命名:
mv sqoop-1.4.7.bin__hadoop-2.6.0 sqoop-1.4.7
3. Modify the configuration file (in the conf directory of sqoop-1.4.7)
mv sqoop-env-template.sh sqoop-env.sh
vim sqoop-env.sh
The modified content is shown in the figure:
4. Configure environment variables
vim ~/.bashrc
Then add the following:
export SQOOP_HOME=/opt/module/sqoop-1.4.7
export PATH=$SQOOP_HOME/bin:$PATH
Finally make it work:
source ~/.bashrc
5. Copy the mysql driver package to /opt/modules/sqoop/lib.
cp ./mysql-connector-java-5.1.31.jar /opt/module/sqoop-1.4.7/lib/
6. Test
sqoop list-databases --connect jdbc:mysql://AY01:3306/ --username root --password MySQL_123