debug db

Syntax

debug db {all | sub-module} [level] [filter] no debug db {all | sub-module} [level] [filter]

Description

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

Thenoform 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. Specifyrxortxdebug logs.

filter

Specifies supported filters for the db log. Specifytable,column, orclient. 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 isdebug. Optional.

emer

Specifies storage of debug logs with a severity level ofemergencyonly.

crit

Specifies storage of debug logs with severity level ofcriticaland above.

alert

Specifies storage of debug logs with severity level ofalertand above.

err

Specifies storage of debug logs with severity level oferrorand above.

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

Specifies storage of debug logs with severity level ofwarningand above.

info

Specifies storage of debug logs with severity level ofinfoand above.

debug

Specifies storage of debug logs with severity level ofdebug(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 keywordallmay 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 severitydebug:

switch#debug db all severity debug

Configuring thetxsubmodule withtable Interfacefilter and severitydebug:

switch#debug db tx table Interface severity debug

Configuring therxsubmodule withtable Interface column statisticsfilter and severitydebug:

switch#调试db rx表界面列统计everity debug

Disabling therxsubmodule:

switch#no debug db rx

Disabling thetxsubmoduletable Interface:

switch#no debug db tx table Interface