User Tools

Site Tools


This is an old revision of the document!

How to repair corrupted sqlite database

Sqlite databases on Android devices are by definition very stable. However we have own experience that databases can be corrupted. This may be due to wrong closing database or kill Locus app. The result is that Locus is not able open the map file or map deletes itself. Luckily sometimes it is possible to repair corrupted database.

How to

Following steps require working with the command line.

  • Copy corrupted map file (sqlite database) from your device to PC
  • Unpack it and place corrupted database file into the same directory as sqlite3.exe
  • Start cmd and navigate to the directory with map file
  • Run
echo .dump | sqlite3.exe name_of_map.sqlitedb > name_of_map_dump.sql
  • and then
sqlite3.exe -init name_of_map_dump.sql name_of_map_fixed.sqlitedb
  • Try import fixed map
manual/advanced/map_tools/corrupted_sqlite.1431665899.txt.gz · Last modified: 2015/05/15 06:58 (external edit)