Asterisk WARNING

Everything works fine (atleast for now) but then I keep getting the following in my console logs. Is this an issue waiting to happen?

How do I get rid of this?

WARNING[1413]: db.c:348 ast_db_put: Couldn’t execute statement: SQL logic error`

Thank you in advance

What it is your Asterisk version ?

asterisk 16.1.1

Thanks

Are you running Asterisk as root user ?

Yes I am running Asterisk as root

This problem could be caused by permission issues, but if you re running Asterisk as root and astdb.sqlite running fine, will be needed to collect more information to debug the problem

It can also be caused by a corrupted sqlite3 database on disk, or hardware problems. Does it occur at startup?

I keep getting this error. It does not occur at startup.

Please any ideas on how to fix this please?

Thanks in advance

GOOD NEWS :grin::grin:

FIXED IT!!

STEPS

  1. sqlite3 /var/lib/asterisk/astdb.sqlite3
  2. (Check for integrity using )----> pragma integrity_check;
  3. (Help can be of help too) ----> .help
  4. (You can check tables to see what is inside) ----> .tables
  5. .mode insert
  6. .output mydb_export.sql
  7. .dump
  8. .exit
  9. mv /var/lib/asterisk/astdb.sqlite3 /var/lib/asterisk/astdb.sqlite3.orig
  10. sqlite3 /var/lib/asterisk/mydb.db < mydb_export.sql (mydb_export.sql will most likely be in your pwd)
  11. sqlite3 /var/lib/asterisk/astdb.sqlite3
  12. analyze;
  13. .exit

This solved the problem.
No more WARNING signs.

Thank you guys.
Also, thanks to this [https://totoshko88.wordpress.com/2016/09/21/elastix-warning2390-db-c332-ast_db_put-couldnt-execute-statment-sql-logic-error-or-missing-databas](http://Totoshko88 Site)e/