debug db

Syntax

debug db {all | sub-module} [level <MINIMUM-SEVERITY>] [filter]

no debug db {all | sub-module} [level <MINIMUM-SEVERITY>] [filter]

Description

Enables or disables debug logging for a db module or submodules, with an option to filter by specific criteria.

The no form of this command disables debug logging for the db module or submodule.

Command context

Manager (#)

Parameters

all

Enables all submodules for the db log.

sub-module

Enables debug logging for supported submodules. Specify rx or tx debug logs.

filter

Specifies supported filters for the db log. Specify table, column, or client. Optional

severity (emer|crit|alert|err|notice|warning|info|debug)

Selects the minimum severity log level for the destination. If a severity is not provided, the default log level is debug. Optional.

emer

Specifies storage of debug logs with a severity level of emergency only.

crit

Specifies storage of debug logs with severity level of critical and above.

alert

Specifies storage of debug logs with severity level of alert and above.

err

Specifies storage of debug logs with severity level of error and above.

notice
Specifies storage of debug logs with severity level of notice and above.
warning

Specifies storage of debug logs with severity level of warning and above.

info

Specifies storage of debug logs with severity level of info and above.

debug

Specifies storage of debug logs with severity level of debug (default).

Authority

Administrators or local user group members with execution rights for this command.

Usage

DBlog is a high performance, configuration, and state database server logging infrastructure where a user can log the transactions which are sent or received by clients to the configuration and state database server. It can be enabled through the CLI and REST, and also supports filters where a user can filter out logs on the basis of table, column, or client. It is helpful for debugging when the user wants to debug an issue with a particular client, table, or column combination. It is not enabled by default. A combination of filters can also be applied to filter out messages based on table, column, and client.

There are three submodules for the "db" module:
  1. all: When All is enabled, no filters are applied to any of the debug logs, even if other submodules are configured with filters.

  2. tx: If enabled, only the replies and notifications sent out for the initial and incremental updates are logged.

  3. rx: If enabled, only the transactions sent to the configuration and state database server are logged.

The keyword all may be used to enable or disable debug logging for all sub-modules. Also a combination of filters can be used to filter the message types.

If the table or client filter is applied, then the messages belonging to this specific table or client will be logged. The column filter can also be applied to further filter messages on a table, providing a mechanism to filter messages on a column. The table and client filter can be used in combination or separately, but column can only be used in conjunction with table.

Examples

Configuring all submodules with severity debug:

switch# debug db all severity debug

Configuring the tx submodule with table Interface filter and severity debug:

switch# debug db tx table Interface severity debug

Configuring the rx submodule with table Interface column statistics filter and severity debug:

switch# debug db rx table Interface column statistics severity debug

Disabling the rx submodule:

switch# no debug db rx

Disabling the tx submodule table Interface:

switch# no debug db tx table Interface