Fast Object Database for Java - with JPA/JDO support

Size of recording directory keeps growing



I am enabling recording at ObjectDB server...  The database is quite busy updating state of objects. I am observing that the recording directory (*.odr.. 19GB!!) is keep growing, a hundred times bigger that the main database file (*.odb .. 182 MB).

My question: How to limit the size or history of recording? Is there any setting in configuration file?

Thank you


Below are sizes of our database files:

Main database:

nef@l1:~/objectdb$ ls -lah db/cloudai/genose.odb 
-rw-r--r-- 1 nef nef 182M May 13 17:38 db/cloudai/genose.odb

Recording directory

nef@l1:~/objectdb$ ls -lah db/cloudai/genose.odr/
total 19G
drwxr-xr-x 2 nef nef 4.0K May 11 12:28 .
drwxr-xr-x 5 nef nef 4.0K May  9 19:14 ..
-rw-r--r-- 1 nef nef 120M Apr 30 23:27 3500781.odb
-rw-r--r-- 1 nef nef 143K May  1 00:47 3500781.odr
-rw-r--r-- 1 nef nef  10M May  2 03:54 3501859.odr
-rw-r--r-- 1 nef nef 3.3K May  2 03:55 3578797.odr
-rw-r--r-- 1 nef nef 3.3K May  2 03:55 3578812.odr
-rw-r--r-- 1 nef nef 3.3K May  2 03:56 3578823.odr
-rw-r--r-- 1 nef nef 8.4K May  2 04:00 3578842.odr
-rw-r--r-- 1 nef nef  33M May  4 08:57 3578890.odr
-rw-r--r-- 1 nef nef 3.0G May  4 21:05 3811850.odr
-rw-r--r-- 1 nef nef 2.2G May  6 21:21 5819959.odr
-rw-r--r-- 1 nef nef 2.8G May  9 19:13 7303299.odr
-rw-r--r-- 1 nef nef 3.2M May 11 12:28 9100769.odr
-rw-r--r-- 1 nef nef  11G May 13 18:25 9123744.odr
-rw-r--r-- 1 nef nef    0 May 11 12:28 active

First, please check the recording mode in the configuration file. If it is "all" you can save a lot of space (and improve performance) by switching to the "write" mode.

ObjectDB does not purge old recording files. However, you can delete old odr files manually or from your application. To be on the safe side, always keep an odb file synchronized with the first odr file that you keep. For example, in your directory it is now 3500781.odb, a snapshot of the database at transaction #3500781, and 3500781.odr, recording of transactions after transaction #3500781. If you want to delete all the odr files except the last one, 9123744.odr, you should first prepare a snapshot database, 9123744.odb, using the Replayer.

ObjectDB Support
ObjectDB - Fast Object Database for Java (JPA/JDO)

I don't understand why the odb file in that directory is so old.  When recording, shouldn't the odb snapshot be up to date with the latest odr file?

im trying to understand how to use recording and replayer for backup and I read the docs many times but I'm still not sure I understand.  Can you give me a scenario as an example?


e.g. with recording turned on.  What are all the files generated in the odr directory and what they mean, and which ones do I need to keep in order for restoration,and which can be deletes.

When you run the replayer it takes one parameter, the database file.  What does that parameter mean?  Is it the live database file?  Does it mean when I run the replayer, that file specified will be overwritten by the latest odr records?  It also says after running the replayer it will generate another file in the odr directory, why?  

Post Reply