Repair Snapt Aria SQLite DB
  • 28 Jul 2021
  • 1 Minute to read
  • Dark
    Light

Repair Snapt Aria SQLite DB

  • Dark
    Light

If you are receiving an error in Snapt Aria with the keywords: There has been a serious error: SQLSTATE then you likely have a crashed or corrupted SQLite database.

SQLite and Snapt Aria:

Snapt Aria uses two SQLite databases – one which is for Snapt Aria information and one that is for logging data.

These may be marked as “crashed” in the case that you lose power while writing or if something else goes wrong.

The databases are located in “db/” – typically you’ll find them in one of the two directories:

/srv/www/htdocs/db/

or

/usr/local/snapt/program/db/

The databases in these directories are called “log.db” and “snapt.db“.

Snapt-Aria-SQLite-location

You can repair them by running one of the following commands:

Log DB

mv log.db log-broken.db
echo ".dump" | sqlite3 log-broken.db | sqlite3 log.db

WAF DB

mv waf.db waf-broken.db
echo ".dump" | sqlite3 waf-broken.db | sqlite3 waf.db

Snapt DB

mv snapt.db snapt-broken.db
echo ".dump" | sqlite3 snapt-broken.db | sqlite3 snapt.db

Setting Permissions (Important to run this one afterward)

chmod 777 log.db waf.db snapt.db

After you have run the command you should now be able to login to your Snapt Aria interface.

If this does not solve the problem please restore a backup, or log a ticket at: Snapt support