Corrupt database found - any advise?

Got an alert today that my hub DB is growing anf I need to do a soft reset.
Downloaded a backup and ran soft reset to get this message:

Corrupt database found
Hub cannot continue. Please try the following actions:

Using port 8081, I tried to:
-Shutdown and restart again
-Disconnect from Electricity for 30 minutes and restart
-Restore from previous version
-Multiple rebboots
-Ran "http://hubIP/hub/advanced/flushClassloaderCaches" - ended with OK message

Nothing worked. still getting the same message.
I am on the hub protect plan and issued a support Email.
Any other things I can do?
Also, if I refresh the web page quick enough I can see the hub gets to 100% loading and then the message apears.
Thanks,

Just to confirm, after you did the soft reset, did you try restoring the backup you downloaded, or one from the list in the Backup / Restore section of the UI?

1 Like

after the soft reset I can not access the hub (well, I can but only the menu show up with error message). Thus, I could not restore from backup.
What I could do was using port 8081 and run 'Restore previous version' only.
Is that what you mean?

That was not what I meant, and I don't believe that will restore the database. It would be for HE staff to comment, but my assumption is that roles back the software, not the database.

When going to settings I get:


and the message on the right upper side is:
image

Are you using the app on your phone / tablet when you get the 500 errors above?

No. this is on my laptop

Hmmm, this is probably beyond my expertise I'm afraid. May be one for @bobbyD.

One piece of information which may be relevant, which was where I was heading with my last question, is the IP address of the hub, just to confirm it hasn't changed (I'm not expecting this to be the case). I could have understood the mobile app still able to display an interface even if it couldn't communicate with the hub, but to have a page rendered when accessing via a browser wouldn't make any sense if it had been re-assigned a different IP, hence my comment about it being unlikely.

Like I said, probably one for HE support, or others here on the Community. Good luck.

Simon

Thanks you Simon for you effort. I appriciate it.
Amit

2 Likes

Tagging @support, to make sure the Hubitat team sees this.

3 Likes

I have the same problem as of 10 minutes ago. I noticed an alert didn't fire as it should so I went to the page and got the 500 error, reboots aren't helping.

This will only restore the platform version. You will need to restore the database backup.

You should start by pressing the “Download Backups” button (The next to last button on the :8081 screen). It contains the database which you will need when you are able to access the restore screen.

@amithalp & @fleetmack, have you tried powering down the hub, pulling the plug and powering it back up? Not sure if it will make a difference, but worth a try while we wait for @support_team to see the issue.

1 Like

I ended up going to :8081 and downloading the 5 most recent daily backups. Then I did a soft reset and restored the db, seem to be up and running again. For the record, I'm glad I downloaded the backups, but I didn't need to, they were waiting there for me after the soft reset.

1 Like

Yes I did.
I am seeing the available backups but I am not able to get to the restore page to load them.

Yes, the backups remain after a soft reset. It is better to restore them from file than from the hub. Also good to have them saved on a separate device just in case…

Yea, that’s odd. I seem to recall seeing this before and I think there was a command that had to be run to fix it… No luck finding it in my searches yet…

do you mean this command?
Ran "http://hubIP/hub/advanced/flushClassloaderCaches" - ended with OK message

Could be - I assume it didn’t work?

Did you try restarting the hub in Safe Mode? (I doubt it would make a difference with your current issue, but doesn’t hurt to try!)

Hold on......
My life moto of never giving up might work this time.
I let the hub "rest" for an hour and ran soft reset again.
Currently it seems to work. Initializing.....

2 Likes

And......I am live again.
Thank you all for your efforts. I will now rush into buying my third hub as a backup hub.

2 Likes

And to end it with a smile...
My family makes fun of me for investing so much time on my "smart home" saying that they don't like it.
You should have seen my daugther coming to me (during the hub crisis) and saying it is not reasonable that she entered the bathroom and the lights did not switch on automatically.
You never know what you love until you miss it :grinning:

6 Likes