The Local Database

1 General Consideration

By default the application is using a local Sqlite3 database.
Depending on the performance of the machine running the application (IOPS and CPU speed), the local database can handle standard to medium traffic gracefully.
If your application is running without significant delays, there is no need to switch to a remote database. The local Sqlite3 database is very efficient and will effectively help you reduce expenses.

2 Saving the local database

The backup of the local database can be done using a dedicated administration endpoint (see the API documentation).

In order to save the local database manually or programmatically:

  • disconnect applications using the local database (this includes own application)
  • connect to the local database sqlite3 /var/lib/cmd-auth/appdb.sql
  • VACUUM;
  • PRAGMA wal_checkpoint(TRUNCATE);
  • disconnect from the local database
  • save the local database
FAQs