https://github.com/osquery/osquery logo
w

wennan.he

11/03/2022, 9:49 PM
Hi osquery team, does osquery building depends on clang? i am suffering from this err when i am building osquery [ 65%] Building CXX object libs/src/aws-sdk-cpp/CMakeFiles/thirdparty_aws-cpp-sdk-ec2.dir/src/aws-sdk-cpp/aws-cpp-sdk-ec2/source/model/CreateTransitGatewayRouteRequest.cpp.o clang-9: error: unable to execute command: Killed clang-9: error: clang frontend command failed due to signal (use -v to see invocation) clang version 9.0.1 (https://github.com/llvm/llvm-project.git c1a0a213378a458fbea1a5c77b315c7dce08fd05) Target: x86_64-osquery-linux-gnu Thread model: posix InstalledDir: /tmp/osquery-toolchain/usr/bin clang-9: note: diagnostic msg: PLEASE submit a bug report to https://bugs.llvm.org/ and include the crash backtrace, preprocessed source, and associated run script. [ 65%] Building CXX object libs/src/aws-sdk-cpp/CMakeFiles/thirdparty_aws-cpp-sdk-ec2.dir/src/aws-sdk-cpp/aws-cpp-sdk-ec2/source/model/CreateTransitGatewayRouteResponse.cpp.o [ 65%] Building CXX object plugins/config/parsers/CMakeFiles/plugins_config_parsers.dir/prometheus_targets.cpp.o clang-9: note: diagnostic msg: ******************** PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT: Preprocessed source(s) and associated run script(s) are located at: clang-9: note: diagnostic msg: /tmp/EC2Client-912014.cpp clang-9: note: diagnostic msg: /tmp/EC2Client-912014.sh clang-9: note: diagnostic msg:
s

Stefano Bonicatti

11/03/2022, 11:41 PM
It does use clang, which is the toolchain the instructions in the wiki tells you to download; the errors you’re seeing happens when the compiler doesn’t have enough memory. Unfortunately the AWS SDK has a very big C++ file (EC2Client.cpp) which requires around 8GB of RAM to build
A rough measure of how much memory one requires to build osquery is a base of 8GB + 0.5GB per each parallel job
3 Views