Linux Node Setup
This guide walks you through adding a Linux node to BadgerPanel. A node is a server that hosts your game servers - the daemon runs on each node and communicates with the panel to manage game server processes.
Prerequisites
Before installing a Linux node, ensure your server has:
- Docker installed and running
- systemd as the init system (most modern distros)
- curl available
- A supported Linux distribution (Ubuntu 20.04+, Debian 11+, CentOS 8+, Rocky 8+, AlmaLinux 8+)
- Root or sudo access
- Network connectivity to your panel URL (HTTPS)
Creating the Node in the Panel
- Navigate to Admin > Nodes and click Add Node.
- Fill in the node details:
| Field | Description |
|---|---|
| Name | A friendly name for this node (e.g., "US East 1") |
| Description | Optional description for your reference |
| FQDN | The fully qualified domain name or IP address of the server |
| OS | Select Linux |
| Memory | Total memory available for game servers (in MB) |
| Disk | Total disk space available for game servers (in MB) |
| Memory Overallocation | Percentage of memory overallocation allowed (0 = none) |
| Disk Overallocation | Percentage of disk overallocation allowed (0 = none) |
- Click Create. The panel generates a one-line install command.
Running the Install Command
Copy the install command from the panel and run it on your Linux server:
curl -sSL "https://panel.example.com/api/nodes/install/TOKEN" | sudo bashReplace the URL with the actual command shown in your panel. The command includes a unique registration token.
What the Install Script Does
- Detects your OS - identifies your Linux distribution and version
- Downloads the daemon binary - fetches the correct binary for your architecture
- Creates the configuration - writes the config file to
/etc/badger-daemon/config.yaml - Registers with the panel - uses the token to authenticate and register the node
- Installs a systemd service - creates and enables the
badger-daemonservice - Starts the daemon - the daemon begins communicating with the panel immediately
Token Validity
The registration token in the install command is:
- Valid for 1 hour from creation
- One-time use - it cannot be reused after a successful installation
If the token expires or is already used, delete the node in the panel and create a new one to generate a fresh token.
Verifying the Connection
After running the install script, return to the panel and check the node's status in Admin > Nodes.
| Status | Meaning |
|---|---|
| Online | The daemon is connected and communicating normally |
| Offline | The daemon is not sending heartbeats - check if the service is running |
| Pending | The node was created but the daemon has not connected yet |
| Error | The daemon reported an error - check the daemon logs for details |
The node should show as Online within a few seconds of completing the installation.
Service Management
The daemon runs as a systemd service called badger-daemon. Use standard systemctl commands to manage it:
# Check the service status
systemctl status badger-daemon
# Stop the daemon
systemctl stop badger-daemon
# Start the daemon
systemctl start badger-daemon
# Restart the daemon
systemctl restart badger-daemon
# Disable the daemon from starting on boot
systemctl disable badger-daemon
# Re-enable starting on boot
systemctl enable badger-daemonViewing Logs
Use journalctl to view daemon logs:
# Follow live logs
journalctl -u badger-daemon -f
# View the last 100 lines
journalctl -u badger-daemon --tail 100
# View logs from the last hour
journalctl -u badger-daemon --since "1 hour ago"
# View errors only
journalctl -u badger-daemon -p errResource Limits
Resource limits control how much of the node's hardware is available for game servers.
Memory
Set the total memory available in the node settings. Game servers cannot be created if the node's allocated memory would exceed the limit. Use memory overallocation to allow allocating more memory than physically available - useful when not all servers run at peak usage simultaneously.
Disk
Set the total disk space available in the node settings. Similar to memory, disk overallocation allows allocating more disk space than physically available.
Overallocation
Overallocation is expressed as a percentage:
- 0% - no overallocation. If the node has 16 GB of memory, you can allocate exactly 16 GB across all servers.
- 50% - allows allocating 150% of the physical resource. A 16 GB node could have 24 GB allocated across servers.
- -1 - unlimited overallocation (no enforcement).
Use overallocation carefully. If all servers consume their full allocation at the same time, the node may run out of resources.
Removing a Node
Before removing a node, you must first delete or transfer all servers hosted on it.
- In the panel, go to Admin > Nodes, select the node, and click Delete.
- On the Linux server, stop and remove the daemon:
# Stop and disable the service
systemctl stop badger-daemon
systemctl disable badger-daemon
# Remove the service file
rm /etc/systemd/system/badger-daemon.service
systemctl daemon-reload
# Remove the daemon binary and configuration
rm -rf /etc/badger-daemon
rm /usr/local/bin/badger-daemon
# Optionally remove server data (WARNING: deletes all game server files)
rm -rf /var/lib/badger-daemon