IMPALA-5031: Apply UBSan options to catalogd catalogd runs some C++ code, and that code can have undefined behavior. This patch sets up the catalogd environment to give stack traces and it excludes the libstdc++ undefined behavior from causing a warning to be printed, as described in commit b41c2114f42f92441e96b4.
Change-Id: I520f8620d9b9f516ca5c55da5294de619e8e2d8f Reviewed-on: http://gerrit.cloudera.org:8080/6652 Reviewed-by: Jim Apple <[email protected]> Tested-by: Impala Public Jenkins Project: http://git-wip-us.apache.org/repos/asf/incubator-impala/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-impala/commit/634c2f7b Tree: http://git-wip-us.apache.org/repos/asf/incubator-impala/tree/634c2f7b Diff: http://git-wip-us.apache.org/repos/asf/incubator-impala/diff/634c2f7b Branch: refs/heads/master Commit: 634c2f7b9fcbb96f9c73a1cb6a6ce64780bd5eac Parents: c7fa4dc Author: Jim Apple <[email protected]> Authored: Sat Apr 15 15:09:00 2017 -0700 Committer: Impala Public Jenkins <[email protected]> Committed: Thu Apr 20 03:18:54 2017 +0000 ---------------------------------------------------------------------- bin/start-catalogd.sh | 3 +++ 1 file changed, 3 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-impala/blob/634c2f7b/bin/start-catalogd.sh ---------------------------------------------------------------------- diff --git a/bin/start-catalogd.sh b/bin/start-catalogd.sh index 1046c82..18d2c6a 100755 --- a/bin/start-catalogd.sh +++ b/bin/start-catalogd.sh @@ -70,4 +70,7 @@ if ${CLUSTER_DIR}/admin is_kerberized; then fi . ${IMPALA_HOME}/bin/set-classpath.sh +export UBSAN_OPTIONS="print_stacktrace=1" +UBSAN_OPTIONS="${UBSAN_OPTIONS} suppressions=${IMPALA_HOME}/bin/ubsan-suppressions.txt" +export PATH="${IMPALA_TOOLCHAIN}/llvm-${IMPALA_LLVM_VERSION}/bin:${PATH}" exec ${BINARY_BASE_DIR}/${BUILD_TYPE}/catalog/catalogd ${CATALOGD_ARGS}
