rpk redpanda mode

Enable a default configuration mode.

This command allows you to set one of the following modes: Development, Production, or Recovery.

This command is only available on Linux.

Usage

rpk redpanda mode <mode> [flags]

Mode details

Development mode

Development mode (development or dev) includes the following development-only settings:

  • Sets developer_mode to true. This starts Redpanda with dev-mode only settings, including:

    • No minimal memory limits are enforced.

    • No core assignment rules for Redpanda brokers are enforced.

    • Enables write caching, which is a relaxed mode of acks=all that acknowledges a message as soon as it is received and acknowledged on a majority of brokers, without waiting for it to fsync to disk. This provides lower latency while still ensuring that a majority of brokers acknowledge the write. For more information, or to disable this, see write caching.

    • Bypasses fsync (from Seastar option unsafe_bypass_fsync), which results in unrealistically fast clusters and may result in data loss.

  • Sets overprovisioned to true. Redpanda expects a dev system to be an overprovisioned environment. Based on a Seastar option, setting overprovisioned disables thread affinity, zeros idle polling time, and disables busy-poll for disk I/O.

  • Sets all autotuner tuners to false. The tuners are intended to run only for production mode.

Production mode

Production mode (production or prod) disables dev-mode settings:

  • developer_mode: false

  • overprovisioned: false

It also enables a set of tuners of the autotuner. For descriptions about the tuners, see Tuners in the rpk redpanda tune list command reference.

Recovery mode

Recovery mode (recovery) sets the broker configuration property recovery_mode_enabled to true. This provides a stable environment for troubleshooting and restoring a failed cluster.

Production

  • Enforces optimal runtime checks.

  • Enables all rpk tuners, for you to run rpk redpanda tune.

Development

  • Disables optimal checks and bypasses fsync, which results in unrealistically fast clusters and may result in data loss.

  • Disables all rpk tuners. The tuners are intended to run only for production mode.

Recovery

Sets the broker configuration property 'redpanda.recovery_mode_enabled=true' in your redpanda.yaml. This provides a stable environment for troubleshooting and restoring a failed cluster. Restart required.

Global flags

Value Type Description

--config

string

Redpanda or rpk config file; default search paths are ~/.config/rpk/rpk.yaml, $PWD/redpanda.yaml, and /etc/redpanda/redpanda.yaml.

-X, --config-opt

stringArray

Override rpk configuration settings; -X help for detail or -X list for terser detail.

--ignore-profile

bool

Ignore rpk.yaml and redpanda.yaml; use default settings.

--profile

string

rpk profile to use.

-v, --verbose

bool

Enable verbose logging.