Skip to main content
NetBird uses structured logging with configurable levels and outputs across all components.

Log Levels

NetBird supports the following log levels (from most to least verbose):
The default log level is info for production use.

Client Logging

Log File Locations

Client logs are written to different locations based on the platform:
Rotated logs:
Alternatively, view logs in Event Viewer under Application logs.
Or view via Console.app:

Configure Client Log Level

Set Log Level via Command Line

Available Log Levels

trace level generates extensive logs and should only be used temporarily for troubleshooting.

Set Log Level via Environment Variable

Log Output Destinations

NetBird supports multiple log outputs simultaneously:
Useful for Docker containers and systemd with journal:
Logs are sent to the system syslog daemon.

Temporary Debug Logging

Run with trace logging for a specific duration, then automatically create a debug bundle:
This command:
  1. Sets log level to trace
  2. Enables sync response persistence
  3. Runs for the specified duration
  4. Creates a debug bundle with logs
  5. Restores original log level

Server Logging

Management Server

Configure Log Level

Docker Compose Configuration

View Management Server Logs

Signal Server

Relay Server

Log Rotation

Docker Compose Log Rotation

Configure in your docker-compose.yml:

Linux System Log Rotation

Create /etc/logrotate.d/netbird:

Structured Logging

NetBird uses structured logging with contextual fields:

Log Format

HTTP Request Tracing

All HTTP requests include a unique request ID:

Common Log Patterns

Anonymized Logging

Enable anonymization to hide sensitive information:
Anonymized output:
Anonymization applies to status output and debug bundles, not to server-side logs.

Log Analysis

Search Logs

Docker Logs

Centralized Logging

Sending to External Systems

Troubleshooting Logging Issues

1

Check log file permissions

2

Verify log directory exists

3

Check disk space

4

Test with console output