-
Notifications
You must be signed in to change notification settings - Fork 310
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DAOS-16661 common: Integrate PMDK logging system w/ VOS logging system. #14923
base: master
Are you sure you want to change the base?
Conversation
Ticket title is 'Integrate PMDK logging system w/ VOS logging system.' |
Test stage NLT on EL 8.8 completed with status UNSTABLE. https://build.hpdd.intel.com/job/daos-stack/job/daos//view/change-requests/job/PR-14923/3/testReport/ |
75504b7
to
ad62bd1
Compare
To enable new message in log in NLT. Allow-unstable-test: true Priority: 2 Required-githooks: true Co-authored-by: Jan Michalski <jan.michalski@intel.com> Co-authored-by: Tomasz Gromadzki <tomasz.gromadzki@intel.com> Signed-off-by: Tomasz Gromadzki <tomasz.gromadzki@intel.com>
ad62bd1
to
149320c
Compare
To enable new message in log in NLT. Allow-unstable-test: true Priority: 2 Required-githooks: true Signed-off-by: Tomasz Gromadzki <tomasz.gromadzki@intel.com>
Priority: 2 Allow-unstable-test: true Skip-func-hw-test: false Required-githooks: true Signed-off-by: Tomasz Gromadzki <tomasz.gromadzki@intel.com>
Skip-nlt: true Priority: 2 Allow-unstable-test: true Skip-func-hw-test: false Required-githooks: true Signed-off-by: Tomasz Gromadzki <tomasz.gromadzki@intel.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@grom72 Packaging changes LGTM. Please re-request review from me once you have gotten your two +1s for the core code changes and I will +1 to remove my -1 review. I just don't want my +1 to be misunderstood to be for the core code changes also.
Test stage Functional Hardware Medium UCX Provider completed with status FAILURE. https://build.hpdd.intel.com//job/daos-stack/job/daos/view/change-requests/job/PR-14923/11/execution/node/1683/log |
Test stage Functional Hardware Medium UCX Provider completed with status FAILURE. https://build.hpdd.intel.com//job/daos-stack/job/daos/view/change-requests/job/PR-14923/12/execution/node/635/log |
Skip-nlt: true Priority: 2 Allow-unstable-test: true Required-githooks: true Signed-off-by: Tomasz Gromadzki <tomasz.gromadzki@intel.com>
Skip-list: test_ior_intercept_libpil4dfs:DAOS-16260 Allow-unstable-test: true Signed-off-by: Tomasz Gromadzki <tomasz.gromadzki@hpe.com>
Static analysis of NLT results does not work properly when a warning source code is out of scope of the project. An error is reported in such case and the whole stage status is changed to FAILURE. ``` [NLT results] [-ERROR-] Can't create fingerprints for some files: [NLT results] [-ERROR-] - 'pmdk/.../src/common/set.c' file not found ... [NLT results] Failing build because analysis result contains errors ``` To prevent this problem, all PMDK-related messages are filtered out. NLT results Warnings section will include warnings but will not provide any detail information about location of this warning in the source code. Based on existing format of nlt-errors.json file the most easy way to filtered all PMDK messages is to use the predefined "pmdk/" preffix in the fileName: ``` ... { "fileName": "pmdk/src/../src/common/set.c", "type": "warning in strict mode", "lineStart": 2796, "description": "warning in strict mode", "message": "util_replica_check() Possible silent data corruption. The unsafe shutdown detection (SDS) is not supported in the pool: /mnt/daos_0/e5737f5f-fa54-45d6-b081-9b2769921610/vos-1\nwarning in strict mode", "severity": "NORMAL" }, ... ``` vos logging system should ensure that the file name of each PMDK related message starts with "pmdk/" prefix. The implementation of the solution is provided in daos-stack/daos#14923 PR Signed-off-by: Tomasz Gromadzki <tomasz.gromadzki@hpe.com>
Skip-list: test_ior_intercept_libpil4dfs:DAOS-16260 Allow-unstable-test: true Signed-off-by: Tomasz Gromadzki <tomasz.gromadzki@hpe.com>
All PMDK warnings has been muted in NLT and Fault Injection tests as they can not be processed properly. There is one new PMDK warnings related to non-pmem baked libpmemobj pools. |
NLT results analysis reports an error when it can not get source code of the reported warning. PMDK reports warnings/errors via VOS logging system but the source code is not available. Static analysis of NLT results does not work properly when a warning source code is out of scope of the project. An error is reported in such case and the whole stage status is changed to FAILURE. ``` [NLT results] [-ERROR-] Can't create fingerprints for some files: [NLT results] [-ERROR-] - 'pmdk/.../src/common/set.c' file not found ... [NLT results] Failing build because analysis result contains errors ``` To prevent this problem, all PMDK-related messages are filtered out. NLT results Warnings section will include warnings but will not provide any detail information about location of this warning in the source code. Based on existing format of nlt-errors.json file the most easy way to filtered all PMDK messages is to use the predefined "pmdk/" preffix in the fileName: ``` ... { "fileName": "pmdk/src/../src/common/set.c", "type": "warning in strict mode", "lineStart": 2796, "description": "warning in strict mode", "message": "util_replica_check() Possible silent data corruption. The unsafe shutdown detection (SDS) is not supported in the pool: /mnt/daos_0/e5737f5f-fa54-45d6-b081-9b2769921610/vos-1\nwarning in strict mode", "severity": "NORMAL" }, ... ``` The VOS logging system should ensure that the filename of each PMDK-related message starts with a "pmdk/" prefix. The implementation of the solution is provided in daos-stack/daos#14923 PR Signed-off-by: Tomasz Gromadzki <tomasz.gromadzki@hpe.com>
daos-stack/pipeline-lib#457 landed on master. This change only may affect NLT and Fault Injection tests No need to execute HW and VM Functional Tests Skip-unit-test: true Skip-unit-test-memcheck: true Skip-bullseye: true Skip-fault-injection-test: false Skip-func-test-vm-all: true Skip-func-test-hw: true Signed-off-by: Tomasz Gromadzki <tomasz.gromadzki@hpe.com>
Reported memchecke issue:
has already been fixed on master #15967 daos/src/cart/utils/memcheck-cart.supp Line 735 in 864448e
No other issues in NLT and Fault Injection Tests |
@mchaarawi @jolivier23 @NiuYawei do we need one more complete execution of all tests or the actual validation status is good enough? |
@mchaarawi, @jolivier23 |
Skip-list: test_ior_intercept_libpil4dfs:DAOS-16260 Signed-off-by: Tomasz Gromadzki <tomasz.gromadzki@hpe.com>
src/vos/pmdk_log.c
Outdated
@@ -41,6 +41,29 @@ static void | |||
pmdk_log_function(enum pmemobj_log_level level, const char *file_name, unsigned line_no, | |||
const char *function_name, const char *message) | |||
{ | |||
/* normalize file path - remove leading "../" */ | |||
while ((*file_name == '.') && (*(file_name + 1) == '.') && (*(file_name + 2) == '/')) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, won't this happen even if the log is disabled? Maybe put this in a function and change PMDK_LOG_NOCHECK to a do/while(0) and do this conversion inside the macro?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can do that, but PMDK produces only error/warning messages which should not be disabled at all.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this needs to be updated to put the string conversions inside the macro..unless I'm missing something
Fixed in 7d52d54
Skip-list: test_ior_intercept_libpil4dfs:DAOS-16260 Skip-func-hw-test: true Signed-off-by: Tomasz Gromadzki <tomasz.gromadzki@hpe.com>
src/vos/pmdk_log.c
Outdated
/* Prefix is needed to filter out PMDK messages in NLT results analysis */ \ | ||
/* as it is implemented in https://github.com/daos-stack/pipeline-lib/pull/457 */ \ | ||
\ | ||
char file_name_buff[PMDK_LOG_FUNCTION_MAX_FILENAME] = "pmdk/"; \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
minor nit, we usually put declarations at the top of the current block.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed in: 4f2622c
Fix: put declarations at the top of the current block Skip-list: test_ior_intercept_libpil4dfs:DAOS-16260 Skip-func-hw-test: true Signed-off-by: Tomasz Gromadzki <tomasz.gromadzki@hpe.com>
@daos-stack/daos-gatekeeper |
Skip-list: test_ior_intercept_libpil4dfs:DAOS-16260 Signed-off-by: Tomasz Gromadzki <tomasz.gromadzki@hpe.com>
Unfortunately the latest builds are failing due to a CI issue resolved yesterday. But there is another CI issue #16125 you'll want to wait for too. |
pmemobj
error and warning messages are written by default tostderr
andsyslog()
.PMDK enables redirecting logging messages to user-specific functions.
All error and warning messages are reported using the DAOS logging function, to ensure a coherent events view for VOS and related
pmemobj
functions.Requires:
Before requesting gatekeeper:
Features:
(orTest-tag*
) commit pragma was used or there is a reason documented that there are no appropriate tags for this PR.Gatekeeper: