Dependent Library: yum-y Install gcc+ gcc-c++
The compiler prerequisites are mentioned in the official documentation: GCC C + +, autoconf, Automake, Libtool, Java 6, Java_home set, Maven 3
1: Download the required dynamic library and Hadoop snappy plug-in project
snappy-1.1.2.tar.gz Dynamic Library
Source-archive Maven Jar
2: Compile snappy-1.1.2.tar.gz (gcc g++, etc.)
./configure
Make
Make install
It worked. There are dynamic library files under Usr/local/lib
-rw-r--r--. 1 root root 330020 June 6 11:42 libsnappy.a
-rwxr-xr-x. 1 root root 953 June 6 11:42 libsnappy.la
lrwxrwxrwx. 1 root root 6 11:42 libsnappy.so-libsnappy.so.1.2.1
lrwxrwxrwx. 1 root root 6 11:42 libsnappy.so.1-libsnappy.so.1.2.1
-rwxr-xr-x. 1 root root 164196 June 6 11:42 libsnappy.so.1.2.1
3:maven edit source-archive under Truch pack
PS: Installing Maven
wget Http://repos.fedorapeople.org/repos/dchen/apache-maven/epel-apache-maven.repo-O/etc/yum.repos.d/ Epel-apache-maven.repo
Yum-y Install Apache-maven
Problems encountered:
MVN Package
Error:could not find or Load main class Org.codehaus.plexus.classworlds.launcher.Launcher
Because the MAVEN environment did not import execution: Export M2_home=/usr/share/maven export path= $PATH: $M 2_home/bin
Subsequently compiled: MVN package
Problems encountered:
Cannot run Program "autoreconf" installs the dependent libraries mentioned above
Cannot FIND-LJVM this error because the libjvm.so that installed the JVM was not linked to/usr/local/lib. If your system is AMD64, you can do the following to solve the problem:
ln -s /usr /java/jdk17.0_75/jre/lib/amd64/ server/libjvm.< Span class= "crayon-v" >so /usr /local/lib/
< Span class= "crayon-v" > < Span class= "Crayon-o" > < Span class= "crayon-v" > then get the compilation Successful jar
Snappy data compression configuration to Hadoop