In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
Editor to share with you how to compile and install hadoop2 on windows, I believe most people do not know much about it, so share this article for your reference, I hope you can learn a lot after reading this article, let's go to know it!
I. compiling Hadoop1.1 deployment compilation environment
Bloggers have tried to use the latest version of the official dependent software and have been beaten over and over again several times, so at least at the time of this writing, the latest version of the dependent software can not be compiled properly, so it is still the officially recommended version.
The address of the network disk is provided. I download various environment software. the dependency packages below are explained based on the files in the network disk.
Jdk-7u79-windows-x64.exe
JDK don't say much, install it directly, be careful not to install it under the path with spaces, that's right, it's Program Files, install it directly to D:\ Java, it's pretty good (in fact, it can't be installed, or it will be a bit of trouble to configure environment variables, the less trouble the better, you know). The installation directory where you need to set the environment variable JAVA_HOME=jdk also needs to add% JAVA_HOME%\ bin to PATH.
Apache-maven-3.3.9-bin.zip MAVEN java's dependent packages and compilation tools can be downloaded and unzipped. You need to add the unzipped directory\ bin of MAVEN to PATH.
Cmake-3.5.2-win32-x86.zip cmake compiler tool, download and decompress it. You need to add the unzipped directory\ bin of cmake to PATH.
Cygwin64-downloaded.zip cygwin is a linux command line simulation tool under windows. In fact, all the commands written in maven are based on linux, so the execution of the script under windows will report an error, so I provide a compressed package version, which can be decompressed directly. (of course, there is an installation version in the directory, but I don't think it's necessary.) you need to add cygwin's unzipped directory\ bin to PATH.
The data serialization package provided by protoc-2.5.0-win32.zip google contains only one protoc.exe, which can be downloaded and decompressed. You need to add the unzipped directory of protoc to PATH.
Zlib-1.2.7.3-binary.zip zlib compression library, this online binary version can not be found, this binary is compiled by myself, so if there is a problem, ahem, please download the source version and compile it yourself. Download and decompress it. You need to add the unzipped directory of the environment variable ZLIB_HOME=zlib.
Vs2010 / winsdk7.1 in fact, the blogger at first intended to use winsdk, but later found that zlib could not find a compiled version but had to compile, so they installed vs2010. All later also used vs2010's cmd. PS. The blogger also put the vs installation package (English version) in it (of course, you can look it up on the Internet).
Hadoop-common.git.source.zip hadoop source code package, in fact, the blogger git down and then packaged, conditional students to git it.
Git clone git://git.apache.org/hadoop-common.git
1.2 Test the compilation environment
Find Visual Studio Command Prompt (2010) in the menu to open a command line window and type the following command to test:
Java-versionmvn-versiontarprotocecho% ZLIB_HOME%
In fact, basically PATH is not configured, just reset it in cmd. Do not turn it off after verification, we are still compiling on this command line.
1.3 compile ~ before compilation, you have to set an environment variable, which is only the platform for compilation:
Set Platform=x64
Oh, I forgot to change the directory to the source directory of hadoop: # # enter the drive letter directly: you can switch disks, such as Pcd, and cut to the corresponding disk to perform cd operation cd P:\ Code\ hadoop-common, and then you can enter the maven command to compile hadoop.
Mvn package-Pdist,native-win-DskipTests-Dtar
Well, with any luck, you can collect the translated bag and so on.
Careful students can take a look at the picture above there is a "colored egg" oh *
By the way, the compiled file is in hadoop-common\ hadoop-dist\ target\ hadoop-3.0.0-SNAPSHOT.tar.gz
The above is all the contents of the article "how to compile and install hadoop2 on windows". Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.