PMDK man page

librpma

NAME

rpma_log_set_threshold - set the logging threshold level

SYNOPSIS

      #include <librpma.h>

      int rpma_log_set_threshold(enum rpma_log_threshold threshold,
                      enum rpma_log_level level);

      enum rpma_log_level {
              RPMA_LOG_DISABLED,
              RPMA_LOG_LEVEL_FATAL,
              RPMA_LOG_LEVEL_ERROR,
              RPMA_LOG_LEVEL_WARNING,
              RPMA_LOG_LEVEL_NOTICE,
              RPMA_LOG_LEVEL_INFO,
              RPMA_LOG_LEVEL_DEBUG,
      };

      enum rpma_log_threshold {
              RPMA_LOG_THRESHOLD,
              RPMA_LOG_THRESHOLD_AUX,
              RPMA_LOG_THRESHOLD_MAX
      };

DESCRIPTION

rpma_log_set_threshold() sets the logging threshold level.

Available thresholds are:

Available threshold levels are defined by enum rpma_log_level:

THE DEFAULT LOGGING FUNCTION

The default logging function writes messages to syslog(3) and to stderr(3), where syslog(3) is the primary destination (RPMA_LOG_THRESHOLD applies) whereas stderr(3) is the secondary destination (RPMA_LOG_THRESHOLD_AUX applies).

RETURN VALUE

rpma_log_syslog_set_threshold() function returns 0 on success or a negative error code on failure.

ERRORS

rpma_log_set_threshold() can fail with the following errors:

SEE ALSO

rpma_log_get_threshold(3), rpma_log_set_function(3), librpma(7) and https://pmem.io/rpma/