Databases corrupted repeatedly

So I have three databases. They are made up of both imported and indexed files. It seems that no matter how careful I am to properly open and close db’s, shut down DTPro properly, etc. they get corrupted. By that I mean when I start up DT it gives the “database already in use!” error, and then the db cannot be opened (when I double click it just makes an error sound - no message or anything).

I know how to fix this problem (found the solution on these forums) and have done so about a dozen times now. Am I doing something wrong? Do others have this issue? This is getting pretty aggravating.

That’s certainly not normal. I’ve been using DEVONthink for some nine years. The only time I can recall a garbaged database was when while investigating a user problem, I installed a hack utility that he was using. It immediately damaged a DT Pro database beyond repair. (That was anticipated, so I had a current external backup of the database and lost no data.)

  1. Are your Mac’s operating system and hardware in good shape? Problems such as a failing hard drive or a corrupted disk directory can damage files. The Disk Utility app has a routine to verify the disk directory. The OS X installation disk can check for hardware problems. It’s a good idea to periodically use a maintenance utility such as C ocktail or OnyX (updated for the installed version of OS X) to keep the operating system clean and efficient.

Check the amount of free drive space on your computer. Apple’s engineers recommend keeping about 15% of the rated size free to avoid speed problems and - especially! - to leave ample space for tempory files written by applications and the operating system, including Virtual Memory swap files. Running out of free drive space can result in overwriting and damaging files. (If you run OCR on large PDFs, that can consume a lot of drive space to hold the temporary files.)

Some utility apps deliberately modify sections of the code in OS X, in order to add or modify features or appearance. Installing such hacks increases the possibility of operating system instability and errors, so I’m suspicious of them. Examples include multiple clipboards, typing expanders, contextual menu items, Finder option utilities such as Default Folder and even 1PassWord. If you install hacks, recognize that they may interact with each other (especially if they independently modify the same sections of OS code), and they may break and cause errors any time Apple issues an OS update. That’s why I keep my own Macs almost free of hacks, to reduce the potential for problems.

  1. The “in use” message when attempting to open a database results from either of two prior events: a) there has been an attempt by another copy of a DEVONthink application to access the database, or b) during the previous session the database was not properly closed, perhaps because of a System or application crash, a Force Quit, a forced shutdown of the computer, a power outage, etc. When such an event occurs, DEVONthink attempts to prevent database damage by locking the database.

If this message appears frequently, the cause should be investigated and corrected.

Check in ~/Library/Logs/CrashReporter/. Are there crash reports for the DEVONthink application? If there’s a persistent problem, please copy a recent crash report and a copy of your System Profile to Support.

  1. You didn’t indicate whether or not you are using some approach, such as DropBox, to synchronize your databases on more than one computer. If that’s the case, that would be important information. DropBox simply isn’t as reliable as direct Finder copies between computers, or the use of an intermediary such as a portable drive. If DropBox is used it would be prudent to make a local backup after each session (I recommend creating database archive backups as the integrity of the database is always checked).

Later this year a new Sync procedure for DEVONthink is planned, that will provide more options for sync, and provide better reliability for cloud-based sync.