When opening base I try to open a .odb file but writer opens and i see apage of junk. Also there is a .odb.lck file. what is this and how do i fix the problem?
It appears some file in the .odb is really messed up. Without looking into each of the zipped files with scrutiny, it is not something easily solved.
The only solution, possibly, is to at least save the data. See my answer in this post (click here) for such possibility.
Thanks! Did not have data yet. Still in Devel so able to recreate tables, relationships and forms. I’ll try suggestion later.
The standard embedded database tends to be unstable. You should look into using a split database.
The thing about a database that is very different from something like a text file, is that the data is binary and is generally highly, and tightly integrated, like in the internal indexes. You can’t simply fix it, or patch it up up somehow, no matter how smart or clever you are. Ok, yes, sometimes, rarely, you can recover from a very simple problem. I’ll give your success rate at much less than 1%.
All software can go bonk at times, and the best way to deal with this issue is to make regular backups that you can later easily recover from. (For what it’s worth, I have never found my HSQLDB embedded database to be particularly unstable.)
Recovering using your backup from a prior snapshot is nearly 100% reliable.
That being said, you will loose any work that occurred after the backup (snapshot) was done.
You might notice that I have been working on a LO backup tool called AnnotatedBackups. You can get more info about how to use it at GitHub. It’s what I use every day now.
One database I liked from years past was Btrieve. It had a feature that allowed a log to be created to record record changes, as records were edited. Then if the software crashed, you could restore from your snapshot, and then roll back all of your changes, and not loose anything, except what was in the most recent transaction, which was minimal, and could not be protected. I loved this feature and used it often, especially during development.
BTW, I revised your Q title. Please keep your titles short and to the point. Thanks.