Database not saving


#1

PhantomBot Version: 2.3.9.1
OS Version: Windows/Ubuntu
Java Version: 8
Stock PhantomBot: Yes

Let us know what help you need:

So I was working on a new module for a mate the other day and noticed that the database wasn’t being updated yet the panel was reporting data correctly. I am assuming there is some form of caching going on which i thought would have been resolved by shutting the bot down. However this doesn’t seem to be the case. The DB updates the first couple of times anything is changed, but then seems to stop.

So is this a bug or do I just not understand when and how the bot updates the database? The issue I have is that my mates bot is always on and hosted and need to shut it down for a scheduled maintenance :confused: but not sure how old the data in the database is, unsure as to whether it is going to save and he has a lot of points data that we don’t want to risk loosing :face_with_head_bandage:

Is there anyway to force a database save?


#2

Anytime a write is made the database will save it almost instantly, unless you have a corrupted database this should not be an issue at all. If your custom script does some writes, there could be a chance that you corrupted the database.


#3

ah that is not what i wanted to hear…

Ok seems I am currently up shits creak without a paddle then. cheers dude


#4

You can use save in the bot console to try a force save, but like I said, it should save by itself all the time.


#5

Ok, I shall see if i can trigger that. it is running as a service using systemctl

appreciate the help :slight_smile:


#7

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.