具體步驟可以參照這里:
https://github.com/apache/incubator-doris/wiki/Doris-Install
一、編譯(物理機直接編譯)
1、編譯 Doris FE 和 BE:[bits/c++config.h] 或 [cstddef] 找不到
[ 9%] Built target Exprs Scanning dependencies of target compile_to_ir_sse [ 9%] Generating /root/incubator-doris-DORIS-0.11.38-release/gensrc/build/doris_ir/doris_sse.bc In file included from /root/incubator-doris-DORIS-0.11.38-release/be/src/codegen/doris_ir.cpp:20: In file included from /root/incubator-doris-DORIS-0.11.38-release/be/src/codegen/codegen_anyval_ir.cpp:20: In file included from /root/incubator-doris-DORIS-0.11.38-release/be/src/runtime/string_value.hpp:21: In file included from /root/incubator-doris-DORIS-0.11.38-release/be/src/runtime/string_value.h:23: In file included from /root/incubator-doris-DORIS-0.11.38-release/be/src/udf/udf.h:21: In file included from /root/incubator-doris-DORIS-0.11.38-release/thirdparty/installed//include/boost/cstdint.hpp:36: In file included from /root/incubator-doris-DORIS-0.11.38-release/thirdparty/installed//include/boost/config.hpp:44: /root/incubator-doris-DORIS-0.11.38-release/thirdparty/installed//include/boost/config/select_stdlib_config.hpp:18:12: fatal error: 'cstddef' file not found # include <cstddef> ^ 1 error generated. make[2]: *** [src/codegen/CMakeFiles/compile_to_ir_sse.dir/build.make:63: /root/incubator-doris-DORIS-0.11.38-release/gensrc/build/doris_ir/doris_sse.bc] Error 1 make[1]: *** [CMakeFiles/Makefile2:224: src/codegen/CMakeFiles/compile_to_ir_sse.dir/all] Error 2 make: *** [Makefile:130: all] Error 2
編譯過程中可能會遇到幾個找不到文件的問題,可以參照https://github.com/apache/incubator-doris/issues/297的辦法處理,
有的只配置環境變量就可以,有的還需要修改CMake文件中的關聯,
2、變量定義
[ 12%] Built target CodeGen [ 13%] Building CXX object src/common/CMakeFiles/Common.dir/logconfig.cpp.o /root/incubator-doris-DORIS-0.11.38-release/be/src/common/logconfig.cpp: In function ‘bool doris::init_glog(const char*, bool)’: /root/incubator-doris-DORIS-0.11.38-release/be/src/common/logconfig.cpp:68:5: error: ‘FLAGS_log_filenum_quota’ was not declared in this scope FLAGS_log_filenum_quota = config::sys_log_roll_num; ^~~~~~~~~~~~~~~~~~~~~~~ /root/incubator-doris-DORIS-0.11.38-release/be/src/common/logconfig.cpp:99:9: error: ‘FLAGS_log_split_method’ was not declared in this scope FLAGS_log_split_method = "day"; ^~~~~~~~~~~~~~~~~~~~~~ /root/incubator-doris-DORIS-0.11.38-release/be/src/common/logconfig.cpp:102:9: error: ‘FLAGS_log_split_method’ was not declared in this scope FLAGS_log_split_method = "hour"; ^~~~~~~~~~~~~~~~~~~~~~ /root/incubator-doris-DORIS-0.11.38-release/be/src/common/logconfig.cpp:105:9: error: ‘FLAGS_log_split_method’ was not declared in this scope FLAGS_log_split_method = "size"; ^~~~~~~~~~~~~~~~~~~~~~ make[2]: *** [src/common/CMakeFiles/Common.dir/build.make:135: src/common/CMakeFiles/Common.dir/logconfig.cpp.o] Error 1 make[1]: *** [CMakeFiles/Makefile2:307: src/common/CMakeFiles/Common.dir/all] Error 2 make: *** [Makefile:130: all] Error 2
奈何技不如人,這個問題解決不了,官方的建議是使用docker環境編譯,
通過github上聯系了官方,要了個編譯好的版本去部署了,
二、部署
1、添加BE后,FE日志報:WARN 31 [HeartbeatMgr.runAfterCatalogReady():135] get bad heartbeat response: type: BACKEND, status: BAD, msg: actual backend local ip: 127.0.0.1
這個很大可能是配置文件priority_networks = 172.20.144.233/24有問題,多網卡出問題可能大一點,如果影響不大,可以把地址都配置上,
2、查看服務狀態時,若報錯信息是refused,除了可能的通信故障,還可能是你沒啟動服務,
所以建議確認節點上相應的服務啟動后,再去看服務狀態,