| title | Runtime Data |
|---|---|
| description | Understand where SynapS3 stores configuration, metadata, cache data, and what to back up. |
SynapS3 stores configuration, metadata, and cached object data on local disk. Place this data on durable storage. A usable backup must keep the database and cache at the same recovery point.
~/.synaps3/
config.toml
admin-initial-password
db/
synaps3.db
synaps3.db-shm
synaps3.db-wal
cache/
SQLite WAL and SHM files are expected. Explicit database.dsn and cache.dir values take precedence over defaults.
The container uses /var/lib/synaps3:
/var/lib/synaps3/
config.toml
admin-initial-password
db/
cache/
The Docker deployment mounts this path through the synaps3-data volume. Docker-specific lifecycle and backup commands are documented on the Docker Deployment page.
| Data | Why it matters |
|---|---|
config.toml |
Holds stable runtime settings when they are not environment-managed. |
admin-initial-password |
Stores the generated Admin password for non-interactive init and password reset. Keep it at 0600; after saving the password securely, retain it only if local CLI commands still need it. |
db/ |
Stores buckets, objects, versions, tasks, users, and storage metadata. |
cache/ |
Holds locally durable object bytes for Filecoin upload and read rehydration. |
| Environment secrets | May hold the Filecoin private key and deployment-specific overrides. |
Keep config.toml, .env, credential files, and exported secrets at permission mode 0600. Do not commit or copy wallet private keys into unprotected archives.
- Check
curl http://127.0.0.1:9090/healthzand record any non-okresult. - Review active and exhausted work with
synaps3 admin task statsandsynaps3 admin task list --status exhausted. - Stop SynapS3 with the service manager used by your deployment so object data, metadata, and task state cannot change during the backup.
Do not create a filesystem archive while SynapS3 is still running.
SQLite is the default database. With SynapS3 stopped, back up the entire runtime directory so the database, WAL/SHM files, configuration, and cache share one recovery point. This example uses the default source-build path:
tar czf synaps3-data.tgz -C "$HOME/.synaps3" .
tar tzf synaps3-data.tgz >/dev/null
sha256sum synaps3-data.tgz > synaps3-data.tgz.sha256
sha256sum -c synaps3-data.tgz.sha256Replace the path when database.dsn or cache.dir points elsewhere, and include those locations in the same recovery point. The archive listing and checksum verification must exit successfully. Store synaps3-data.tgz and synaps3-data.tgz.sha256 together in protected backup storage.
If the deployment uses PostgreSQL, stop SynapS3 and then:
- Create a database-native backup with
pg_dump, a managed-database snapshot, or the approved PostgreSQL backup tool for your deployment. - Back up the SynapS3 configuration and cache volume separately.
- Label the database backup and volume archive with the same recovery point.
- Verify both artifacts before restarting the service.
The PostgreSQL backup replaces copying a SQLite database directory; it does not replace the configuration and cache backup.
After a successful backup, start SynapS3 with the service manager used by your deployment, then run:
curl http://127.0.0.1:9090/healthz
synaps3 admin task stats/healthz should return {"status":"ok"}. Investigate setup or unhealthy before resuming S3 traffic.
Before restoring a SQLite archive, verify the stored copy:
sha256sum -c synaps3-data.tgz.sha256- Stop SynapS3 and keep S3 traffic disabled.
- Verify the archive checksum and confirm the database and cache have the same recovery-point label.
- Restore the runtime volume into an empty replacement location. For PostgreSQL, restore the database-native backup before attaching the matching configuration and cache data.
- Confirm the restored configuration and credential files are
0600and readable by the SynapS3 account. - Start SynapS3, check
/healthz, review task statistics and exhausted tasks, then read a known object through the S3 API.
Do not combine a database backup with cache data from another point in time.