Install the Dependencies (by Compiling and Installing the Source Code)
Before using the source code for compilation, install GCC/G++, devtoolset-gcc, Autoconf, and CMake on each node. Table 1 lists the versions.
- LLVM must be compiled on CentOS 7.6 so that it can run properly on both OSs. You need to install devtoolset-gcc on CentOS 7.6.
- jemalloc compilation has no restrictions on the environment. If jemalloc is compiled on openEuler, GCC/G++ must be installed on openEuler 20.03 LTS SP1.
Item |
Required Version |
|---|---|
GCC/G++ |
7.3.0 |
devtoolset-gcc |
7 |
Autoconf |
2.69 |
CMake |
3.13.4 |
Installing LLVM
The following operations must be performed on the management node and all compute nodes.
- Download https://github.com/llvm/llvm-project/archive/refs/tags/llvmorg-12.0.1.tar.gz, create an /opt/omni-operator directory on the management node and compute nodes as the root directory for deploying OmniOperator, go to the directory, and upload the package to /opt/omni-operator.
mkdir /opt/omni-operator cd /opt/omni-operator tar zxvf llvm-project-llvmorg-12.0.1.tar.gz mv llvm-project-llvmorg-12.0.1 llvm cd llvm mkdir build
- Go to the build directory, and compile and install LLVM.
cd ./build cmake -DCMAKE_INSTALL_PREFIX=/opt/llvm -DCMAKE_BUILD_TYPE=Release -DLLVM_BUILD_LLVM_DYLIB=true -DLLVM_ENABLE_PROJECTS="clang;libcxx;libcxxabi" -G "Unix Makefiles" ../llvm make -j4 make install
- Create a lib directory in /opt/omni-operator and copy /opt/omni-operator/llvm/lib/libLLVM-12.so to /opt/omni-operator/lib.
mkdir /opt/omni-operator/lib cp /opt/omni-operator/llvm/lib/libLLVM-12.so /opt/omni-operator/lib/
The /opt/omni-operator, /opt/omni-operator/llvm, and /opt/omni-operator/lib directories can be customized.
Installing jemalloc
The following operations must be performed on the management node and all compute nodes.
- Download https://github.com/jemalloc/jemalloc/archive/refs/tags/5.2.1.tar.gz and upload it to the /opt/omni-operator directory of the management node and compute nodes.
cd /opt/omni-operator/ tar zxvf jemalloc-5.2.1.tar.gz mv jemalloc-5.2.1 jemalloc
- Go to the jemalloc directory, run the script, and install the generated file.
cd jemalloc ./autogen.sh --disable-initial-exec-tls make –j2
- Copy /opt/omni-operator/jemalloc/lib/libjemalloc.so.2 to the /opt/omni-operator/lib directory.
cp /opt/omni-operator/jemalloc/lib/libjemalloc.so.2 /opt/omni-operator/lib/
The /opt/omni-operator/jemalloc directory can be customized.
Parent topic: Installing Dependencies