Confluence with HSQLDB Throws a "User not found" Exception
Symptoms
The following message appears when restarting Confluence, on a site using the evaluation HSQLDB database:
java.sql.SQLException: User not found: SA
Cause
HSQLDB periodically updates its files to represent changes made in the database. In doing so, it deletes the
file on the file system and replaces it with a new one.MY_CONFLUENCE_HOME
\database\confluencedb.data
If you shut down Confluence while the database is deleting and replacing the file, data can be lost. Typically, you will see the above error message when restarting Confluence.
Resolution
Restore the backups contained in the MY_CONFLUENCE_HOME\backups
directory.
If daily backups have been turned off, and no other copy of the data remains, the data is lost.
For more information see http://hsqldb.sourceforge.net/doc/guide/ch01.html#N101C2.
More about Confluence and HSQLDB
If you are using the embedded database, the database files are stored in the \database
directory under your Confluence Home and other important directories.
Note: The embedded HSQLDB database is not suitable for production Confluence sites.
Production sites should use an external database. See our guide to database configuration. When using the default HSQLDB database, you run the risk of irrecoverable data loss because HSQLDB is not transaction safe.
- Corruption is occasionally encountered after sudden power loss. It can usually be corrected using the data recovery procedure documented in our knowledge base.
- HSQLDB is suitable for evaluation purposes, but the risk can only be eliminated by switching databases. This is essential when you move from an evaulation to a production site. External databases may also provide superior speed and scalability.
To find out if you are still using the embedded database, go to > Atlassian Support Tools > Health Check. > General Configuration