Skip to content

Database hosts

Give your customers somewhere to put the databases their servers need.

A database host is a MySQL or MariaDB server the panel can create databases on. When a customer asks for one, the panel makes it, with a user and password of its own.

Open Admin > Databases, which has three tabs.

TabWhat is on it
DatabasesEvery database on every host.
HostsThe database servers themselves.
Database ManagerRoot-level web access to a provisioned host. This tab needs the phpMyAdmin license feature.

Adding a host you already run

Use this method when you already run a MySQL or MariaDB server.

  1. Open the Hosts tab and click Add Host.
  2. Fill in the fields:
FieldDescriptionDefault
Host NameThe name of this host in the panel.empty
Host AddressThe hostname or IP address of the database server.empty
PortThe database port.3306
UsernameA database user that can create databases and users.root
PasswordThe password of that user.empty
Max Databases (0 = unlimited)The limit on the number of databases on this host.0
Affinity - NodesThe nodes that use this host. Leave every box clear to put the host in the global pool.none
Affinity - Kubernetes ClustersThe clusters that use this host. This section appears only when a cluster exists.none
  1. Click Test Connection.
  2. Click Create Host.

The database user needs the rights to create databases, create users, and grant permissions. Use these grants as a minimum:

sql
GRANT CREATE, DROP, ALTER, INDEX, SELECT, INSERT, UPDATE, DELETE,
      CREATE USER, GRANT OPTION ON *.* TO 'badgerpanel'@'%';

Building a new host

The panel can also start a database container on one of your daemon nodes.

  1. Open the Hosts tab and click Provision Host.
  2. Fill in the fields:
FieldDescriptionDefault
Host nameThe name of this host in the panel.empty
EngineMariaDB 11, MySQL 8.0, or PostgreSQL 16.MariaDB 11
Target nodeThe daemon node that runs the container. Kubernetes nodes are not listed.none
Listener allocationThe IP address and port for the container.the first free allocation
Memory (MB)The memory limit.1024
Disk (MB)The disk limit.8192
CPU (%)The CPU limit. 100 means one core.100
Max databases (0 = unlimited)The limit on the number of databases.0
  1. Click Provision host.

The panel shows the host address, the port, the username, and the root password on the result screen.

WARNING

Copy the root password before you click Done. The panel shows the password one time only.

What you can use

Add Host supports MySQL and MariaDB. The form has no engine field, and the panel treats a manually added host as MySQL.

Provision Host also supports PostgreSQL 16. The Database Manager tab does not work with a PostgreSQL host.

Your hosts

The Hosts tab shows four counters at the top: Total Hosts, Total Databases, Restricted, and Public. A restricted host serves only the nodes in its affinity list. A public host serves any node.

The table has these columns:

ColumnContents
NameThe host name, the engine, and the restricted or public state.
ConnectionThe address, the port, and the username.
DatabasesThe current count, and the limit when you set one.
Linked NodeGlobal (any), or the number of linked nodes and clusters.
StatusA Test button. After the test the cell shows Connected or the error text.

Testing a connection

You can run a test in three places:

  • In the Add Host form, with the Test Connection button.
  • On a row of the host list, with the Test button.
  • On the host detail page, with the Test Connection button.

The test makes sure that the panel reaches the host, that the login works, and that the user has the needed rights.

Inside a host

Click a host name to open it. The page shows four counters: Managed DBs, Total Size, Connections, and Uptime.

  • Host Settings holds the same fields as the add form. Leave New Password blank to keep the current password. The Save Changes button appears after you change a field.
  • Maintenance appears on a host the panel built for you. It holds the start and stop controls, the backups and the schedules.
  • Managed Databases lists each database with its name, its user, and a link to the server.
  • Danger Zone holds the delete button.

Maintenance

Lifecycle starts, restarts and stops the host.

Backups covers the whole host, every database on it at once. Leave Incremental off for a complete copy, or turn it on to save only what changed. Click New backup to take one now.

Each backup in the list has a restore button. A restore puts the whole host back to that point, so every database on it goes back together.

WARNING

A restore covers every database on the host at once. To put back one database on its own, use the Back up now action on that database instead.

Schedules runs a backup or a restart on a timetable.

  1. Pick Backup or Restart.
  2. Type the timing, such as 0 3 * * * for 03:00 every day.
  3. For a backup, choose whether it is incremental.
  4. Click to add it.

Each schedule shows its next run. Use the on and off button to pause one without deleting it, and the bin to remove it.

If the list reads that it could not be loaded, that is not the same as being empty. Retry it.

The databases on it

The Databases tab lists every database across every host. The table columns are Database, Server, Owner, Host, and Created.

Use the search box to find a database, a server, or a user. Use the host list to show one host only.

Click Open on a row to open that database in the Database Manager.

The database manager

The Database Manager gives an administrator a web interface to a provisioned host. BadgerPanel runs a phpMyAdmin container for this purpose.

The panel builds a single-use sign-on token that lasts five minutes. The browser then opens phpMyAdmin as the database user. No password passes through the browser.

The tab appears when two conditions are true:

  • Your license includes the phpMyAdmin feature.
  • The phpMyAdmin setting is on.

The tab lists provisioned hosts only. A host with an unsupported engine shows a disabled tile.

What to open in the firewall

The database host must accept connections from:

  • The panel server, for creation and management.
  • The game server nodes, so that the game servers reach their databases.

Open the database port (3306 by default) to both sources.

Deleting a host

The panel blocks the delete while databases exist on the host. Delete or move every database first. The button then becomes active.

Open the host detail page, scroll to Danger Zone, and click Delete Host. Confirm the dialog.

The delete removes the host record from the panel. The database server itself keeps running, and the data on it stays.

Next steps

BadgerPanel Documentation