Skip to content

Latest commit

 

History

History
10 lines (10 loc) · 2.57 KB

logging-flags.md

File metadata and controls

10 lines (10 loc) · 2.57 KB
Flag Description
--log New in v21.1: Configure logging parameters, in conjunction with a YAML payload. For details, see Configure logs. If not specified, the default configuration is used.

Note: The deprecated logging flags below cannot be combined with --log. All of the below settings are defined in the YAML payload.
--log-dir Deprecated. To enable logging to files and write logs to the specified directory, use --log and set dir in the YAML configuration.

Setting --log-dir to a blank directory (--log-dir="") disables logging to files.
--log-group-max-size Deprecated. After the logging group (i.e., cockroach, cockroach-sql-audit, cockroach-auth, cockroach-sql-exec, cockroach-pebble, cockroach-rocksdb) reaches the specified size, delete the oldest log file. The flag's argument takes standard file sizes, such as --log-group-max-size=1GiB.

Default: 100MiB
--log-file-max-size Deprecated. After logs reach the specified size, begin writing logs to a new file. The flag's argument takes standard file sizes, such as --log-file-max-size=2MiB.

Default: 10MiB
--log-file-verbosity Deprecated. Only writes messages to log files if they are at or above the specified severity level, such as --log-file-verbosity=WARNING. Requires logging to files.

Default: INFO
--logtostderr Deprecated. Enable logging to stderr for messages at or above the specified severity level, such as --logtostderr=ERROR

If you use this flag without specifying the severity level (e.g., cockroach start --logtostderr), it prints messages of all severities to stderr.

Setting --logtostderr=NONE disables logging to stderr.
--no-color Do not colorize stderr. Possible values: true or false.

When set to false, messages logged to stderr are colorized based on severity level.

Default: false
--sql-audit-dir Deprecated. If non-empty, output the SENSITIVE_ACCESS logging channel to this directory.

Note that enabling SENSITIVE_ACCESS logs can negatively impact performance. As a result, we recommend using the SENSITIVE_ACCESS channel for security purposes only. For more information, see Logging use cases.