Automatic, encrypted backups to your own Google Drive.See plans →

Database credentials

On most servers, FlashBackup signs in to the databases automatically. If the server page shows a yellow "could not be checked" warning, add the credentials here. They stay on your server and are never sent to FlashBackup.

Where settings live

All agent settings are in /etc/flashbackup/agent.json. Edit it as root, then restart the agent:

sudo nano /etc/flashbackup/agent.json
sudo systemctl restart flashbackup-agent
Keep the existing server, agentId, agentSecret and encryptionKey lines exactly as they are. Only add or change the sections below.

MySQL / MariaDB

By default the agent runs as root and uses MySQL's local root login (standard on Ubuntu and Debian), or /etc/mysql/debian.cnf if present. If your MySQL root user has a password, create a dedicated read-only backup user instead:

sudo mysql -u root -p
CREATE USER 'flashbackup'@'localhost' IDENTIFIED BY 'a-long-random-password';
GRANT SELECT, SHOW VIEW, TRIGGER, EVENT, LOCK TABLES, PROCESS, RELOAD ON *.* TO 'flashbackup'@'localhost';
FLUSH PRIVILEGES;

Then add to agent.json:

"mysql": {
  "user": "flashbackup",
  "password": "a-long-random-password",
  "host": "127.0.0.1",
  "port": 3306
}

For a remote database (for example Amazon RDS), set host to its address. The server running the agent must be allowed to connect to it.

PostgreSQL

By default the agent runs pg_dump as the local postgres system user, which works on most installs. To use a password instead:

"postgres": {
  "user": "backup_user",
  "password": "a-long-random-password",
  "host": "127.0.0.1",
  "port": 5432
}

The user needs permission to read every table you want backed up (on PostgreSQL 14+: GRANT pg_read_all_data TO backup_user;).

MongoDB

By default the agent connects to mongodb://127.0.0.1:27017 without a password. If authentication is on:

"mongodb": {
  "uri": "mongodb://backup:PASSWORD@127.0.0.1:27017/?authSource=admin"
}

The user needs the backup role. The mongosh and mongodump tools (MongoDB Database Tools) must be installed.

SQLite

The agent searches common folders for SQLite files. To search elsewhere, add exact files, or skip some:

"sqlite": {
  "scanPaths": ["/home", "/var/www", "/srv", "/opt", "/data"],
  "paths": ["/mnt/storage/app.db"],
  "exclude": ["/home/ubuntu/old-stuff"]
}

Install the sqlite3 tool for safe backups: sudo apt install sqlite3.

Turning a database type off

To stop the agent checking a type at all, add "enabled": false, for example "mongodb": { "enabled": false }.

Check the result

sudo flashbackup-agent scan

This lists every database the agent can see, and any problems. Then click Look for databases again in the dashboard.