File corrupted while reading record: null. Possible solution: use the recovery tool [90030-200]

861 views
Skip to first unread message

Felipe Paschoal

unread,
Nov 6, 2020, 4:20:41 PM11/6/20
to H2 Database
Hello, today one of my dbs failed to connect and presented the following error message:

Unable to obtain connection from database (jdbc:h2:file:C:\Users\Username\.appfiles\db\appdb) for user 'sa': File corrupted while reading record: null. Possible solution: use the recovery tool [90030-200]
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
SQL State  : 90030
Error Code : 90030
Message    : File corrupted while reading record: null. Possible solution: use the recovery tool [90030-200]

As suggested I tried to use the recover tool as instructed by the documentation, the steps I executed were the following:
1. Go to your h2 data file directory
2. java -cp h2-1.4.200.jar org.h2.tools.Recover 
3. Use SQL file generated by the recovery tool to recreate the database

The steps created two files, a .sql and a .txt file, but the SQL generated by the tool didn't have any data or DDL from the database, just some aliases and a bunch of comments.
This is the sql output: https://pastebin.com/DFfwPemP
This is the txt output: https://pastebin.com/6zwCgqN3

Is there any step I'm not doing right or is any other thing I can try to recover the db? Any suggestion is welcome.
Thanks!
Reply all
Reply to author
Forward
0 new messages