[Ganzhou] deployment record of sqoop1.99.3 in ubuntu14 SERVER + hadoop2.2.0 Environment
Source: Internet
Author: User
Step 1: Download, decompress, and configure environment variables:Download sqoop1.99.3http: // mirrors.cnnic.cn/apache/sqoop/1.99.3/ from the official website/
Decompress sqoop to the target directory, my is/home/Fulong/sqoop/sqoop-1.99.3-bin-hadoop200
Configure the environment variables: Export sqoop_home =/home/Fulong/sqoop/sqoop-1.99.3-bin-hadoop200export Path = $ path: $ sqoop_home/binexport catalina_base = $ sqoop_home/serverexport logdir = $ sqoop_home/logs/
Step 2: modify the configuration file:Modify the configuration file Catalina. properties:Vim $ sqoop_home/Server/CONF/Catalina. properties find common in the file. loader, and then add the hadoop jar package path. The final effect is as follows: Common. loader =$ {Catalina. base}/lib, $ {Catalina. base}/lib /*. jar, $ {Catalina. home}/lib, $ {Catalina. home}/lib /*. jar, $ {Catalina. home }/.. /lib /*. jar,/home/Fulong/hadoop/hadoop-2.2.0/share/hadoop/common /*. jar,/home/Fulong/hadoop/hadoop-2.2.0/share/hadoop/common/lib /*. jar,/home/Fulong/hadoop/hadoop-2.2.0/share/hadoop/HDFS /*. jar,/home/Fulong/hadoop/hadoop-2.2.0/share/hadoop/HDFS/lib /*. jar,/home/Fulong/hadoop/hadoop-2.2.0/share/hadoop/mapreduce /*. jar,/home/Fulong/hadoop/hadoop-2.2.0/share/hadoop/mapreduce/lib /*. jar,/home/Fulong/hadoop/hadoop-2.2.0/share/hadoop/tools /*. jar,/home/Fulong/hadoop/hadoop-2.2.0/share/hadoop/tools/lib /*. jar,/home/Fulong/hadoop/hadoop-2.2.0/share/hadoop/yarn /*. jar,/home/Fulong/hadoop/hadoop-2.2.0/share/hadoop/yarn/lib /*. jar
Modify the configuration file sqoop. properties:Vim $ sqoop_home/CONF/sqoop. properties find Org. apache. sqoop. submission. engine. mapreduce. configuration. directory, which is assigned a value using the hadoop configuration file directory. The final effect is as follows: Org. apache. sqoop. submission. engine. mapreduce. configuration. directory =/home/Fulong/hadoop/hadoop-2.2.0/etc/hadoop
!!!!!! Remember !!!!!! Environment variables (such as $ hadoop_home) cannot be used in the sqoop configuration file. Full path is required !!!
Step 3: jar package related work:1) First, merge the oracle JDBC package classes12.jar to be used: I copied to two directories/home/Fulong/sqoop/sqoop-1.99.3-bin-hadoop200/Server/webapps/sqoop/WEB-INF/lib/home/Fulong/sqoop/sqoop-1.99.3-bin-hadoop200/Server/lib
2) solve the log4j package conflict problem due to. properties configuration file common. all hadoop-related jar packages are introduced in the configuration of the loader attribute, while the lib directory of hadoop contains the log4j package, but the version is different from the log4j package of sqoop. We need to remove the sqoop-1.99.3-bin-hadoop200 under the/home/Fulong/sqoop/WEB-INF/Server/webapps/sqoop/log4j-1.2.16.jar/lib directory.
Start:Sqoop is divided into server and client. The server only needs to run on a hadoop node, and the client can run on any node that can run hadoop client.
Start the server first: [email protected]: ~ /Sqoop/sqoop-1.99.3-bin-hadoop200/Server/webapps/sqoop/WEB-INF/Lib $
Sqoop. Sh Server startSqoop Home Directory:/home/Fulong/sqoop/sqoop-1.99.3-bin-hadoop200Setting sqoop_http_port: 12000 setting sqoop_admin_port: 12001 using catalina_opts: adding to catalina_opts:-dsqoop. HTTP. port = 12000-dsqoop. admin. port = 12001 using catalina_base:/home/Fulong/sqoop/sqoop-1.99.3-bin-hadoop200/serverusing catalina_home:/home/Fulong/sqoop/sqoop-1.99.3-bin-hadoop200/serverusing catalina_tmpdir: /home/Fulong/sqoop/sqoop-1.99.3-bin-hadoop200/Server/tempusing jre_home:/usr/lib/JVM/javausing classpath:/home/Fulong/sqoop/sqoop-1.99.3-bin-hadoop200/Server/bin/Bootstrap. jar
Start the client and point it to the server. view the version: [email protected] i008 :~ $ Sqoop. Sh clientsqoop Home Directory:/home/Fulong/sqoop/sqoop-1.99.3-bin-hadoop200Sqoop shell: Type 'help' or '\ H' for help.
Sqoop: 000> set server -- Host fbi003 -- Port 12000 -- webapp sqoopserver is set successfullysqoop: 000> show version -- allclient version: sqoop 1.99.3 revision compiled by mengweid on Fri Oct 18 14:15:53 EDT 2013 server version: sqoop 1.99.3 revision compiled by mengweid on Fri Oct 18 14:15:53 EDT 2013 Protocol Version: [1] sqoop: 000>
At this point, sqoop1.99.3 can be started normally!
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service