Linux Install
BlazeBee can be deployed directly on Linux hosts without containers, providing maximal visibility into the operating system with minimal overhead. Native deployment is recommended for bare-metal servers, virtual machines, and environments where direct access to kernel and hardware interfaces is required.
This page documents installation methods, filesystem layout, and systemd-based service management.
Purpose
Section titled “Purpose”This guide explains:
- How to install BlazeBee on Linux systems
- How to run it as a managed systemd service
- How configuration and permissions are handled
- How to operate BlazeBee in long-running production environments
Prerequisites
Section titled “Prerequisites”Required
Section titled “Required”- Linux distribution (Debian / Ubuntu recommended)
- Systemd
- MQTT broker reachable from the host
- Root or sudo access for installation
Optional
Section titled “Optional”- Dedicated system user for BlazeBee
- Journald for centralized logging
Installation Methods
Section titled “Installation Methods”Debian Package Installation
Section titled “Debian Package Installation”BlazeBee provides prebuilt .deb packages for supported releases.
wget https://github.com/rubtsov-stan/blazebee/releases/download/vX.Y.Z/blazebee.debsudo dpkg -i blazebee.debThis installs:
-
Binary:
/usr/local/bin/blazebee -
Default directories:
/etc/blazebee//var/lib/blazebee/
Any missing dependencies must be resolved manually if the host system is minimal.
Filesystem Layout
Section titled “Filesystem Layout”Recommended directory structure:
/etc/blazebee/ └── config.toml
/var/lib/blazebee/ └── runtime data (if required)
/usr/local/bin/ └── blazebeeThe configuration file location is explicitly defined via environment variables.
Systemd Integration
Section titled “Systemd Integration”BlazeBee is designed to run as a long-lived system service under systemd.
Installing the Unit File
Section titled “Installing the Unit File”A reference unit file is provided in the repository:
sudo cp contrib/systemd/blazebee.service /etc/systemd/system/Reload and Enable
Section titled “Reload and Enable”sudo systemctl daemon-reloadsudo systemctl start blazebeesudo systemctl enable blazebeeSystemd Service Configuration
Section titled “Systemd Service Configuration”Example Unit File
Section titled “Example Unit File”[Unit]Description=BlazeBee - Lightweight System Metrics Collector and MQTT PublisherDocumentation=https://rubtsov-stan.github.io/blazebee/After=network-online.targetWants=network-online.target
[Service]Type=simpleExecStart=/usr/local/bin/blazebeeEnvironment="RUST_LOG=info"Environment="RUST_BACKTRACE=1"Environment="BLAZEBEE_CONFIG=/etc/blazebee/config.toml"
KillMode=mixedKillSignal=SIGTERM
User=blazebeeGroup=blazebee
WorkingDirectory=/var/lib/blazebeeReadWritePaths=/var/lib/blazebeeReadOnlyPaths=/etc/blazebee/config.toml
StandardOutput=journalStandardError=journalSyslogIdentifier=blazebee
Restart=on-failureRestartSec=5sTimeoutStartSec=30TimeoutStopSec=10
[Install]WantedBy=multi-user.targetKey Parameters Explained
Section titled “Key Parameters Explained”-
BLAZEBEE_CONFIGExplicit path to the configuration file. -
KillSignal=SIGTERMEnables graceful shutdown of collectors and MQTT connections. -
Restart=on-failureEnsures automatic recovery on crashes. -
StandardOutput=journalRoutes logs into journald.
Security Hardening
Section titled “Security Hardening”BlazeBee supports strict systemd sandboxing.
Common hardening options:
NoNewPrivileges=truePrivateTmp=truePrivateDevices=trueProtectSystem=strictProtectHome=read-onlyProtectKernelTunables=trueProtectKernelModules=trueProtectControlGroups=trueRestrictNamespaces=trueRestrictAddressFamilies=AF_INET AF_INET6 AF_NETLINKRestrictRealtime=trueThese options:
- Limit filesystem access
- Prevent privilege escalation
- Restrict kernel interaction
Some advanced collectors may require loosening these restrictions.
User and Permissions
Section titled “User and Permissions”Recommended approach:
sudo useradd --system --home /var/lib/blazebee --shell /usr/sbin/nologin blazebeesudo chown -R blazebee:blazebee /var/lib/blazebeeCollectors reading from /proc and /sys usually do not require root privileges, but hardware or power metrics may.
Configuration Management
Section titled “Configuration Management”- Configuration file is read once at startup
- Changes require service restart:
sudo systemctl restart blazebee- Configuration path is defined exclusively via
BLAZEBEE_CONFIG
Logs and Monitoring
Section titled “Logs and Monitoring”Viewing Logs
Section titled “Viewing Logs”journalctl -u blazebee -fLogs include:
- Startup validation
- Collector lifecycle
- MQTT connection state
- Runtime errors
Operational Considerations
Section titled “Operational Considerations”-
Native deployment offers maximum metric fidelity
-
Suitable for long-running production systems
-
Ideal for environments requiring:
- Hardware metrics
- Kernel-level statistics
- Minimal latency
Summary
Section titled “Summary”Native Linux deployment provides the highest level of observability and control over BlazeBee. With systemd integration, hardened execution, and explicit configuration management, BlazeBee can run reliably as a core monitoring component on Linux hosts in production environments.