You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomee.apache.org by mean_bcp <go...@versatilets.com> on 2016/10/05 18:51:10 UTC

KahaDB growth

What configuration options can I use to limit the growth of my kahadb files?

It grows over time until we run out of space.

I looked at http://activemq.apache.org/kahadb.html but I am not sure which
options to choose, especially because we are running 5.10.0. Upgrade to 5.14
is possible, but would like to fully test that first, so if there's anything
I can do in 5.10.0, please let me know.



--
View this message in context: http://tomee-openejb.979440.n4.nabble.com/KahaDB-growth-tp4680295.html
Sent from the TomEE Users mailing list archive at Nabble.com.

Re: KahaDB growth

Posted by Romain Manni-Bucau <rm...@gmail.com>.
ok, then it is more for activemq than tomee but cleanupInterval does that
job so check with your app what is happening maybe


Romain Manni-Bucau
@rmannibucau <https://twitter.com/rmannibucau> |  Blog
<https://blog-rmannibucau.rhcloud.com> | Old Wordpress Blog
<http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> |
LinkedIn <https://www.linkedin.com/in/rmannibucau> | Tomitriber
<http://www.tomitribe.com> | JavaEE Factory
<https://javaeefactory-rmannibucau.rhcloud.com>

2016-10-06 18:43 GMT+02:00 mean_bcp <go...@versatilets.com>:

> Thank you.
>
> What I'm looking for is some advice for limiting the size of the files. I
> am
> not sure which options can be used, and what the ramifications are.
> Currently my db.data is 6GB and growing - does this mean we are not
> processing the messages fast enough, or we are saving them too long, etc. I
> am not sure how to interpret or fix this issue. If anyone has experience
> with this, I would appreciate a nudge in the right direction.
>
> Also, what is the purpose of the db-xx.log files (I'm assuming some sort of
> restore?) and the ramifications of deleting them as a part of an automated
> cleanup script? Or can I tweak the kahaDB config to remove them for me?
>
>
>
> --
> View this message in context: http://tomee-openejb.979440.
> n4.nabble.com/KahaDB-growth-tp4680295p4680303.html
> Sent from the TomEE Users mailing list archive at Nabble.com.
>

Re: KahaDB growth

Posted by Romain Manni-Bucau <rm...@gmail.com>.
you can
read org.apache.activemq.store.kahadb.MessageDatabase#createPageFile to
understand how it works

if you remove them yourself the in memory index of kahadb will be broken
and then behavior is up to the good will of the process which is rarely in
a good mood if you get the idea ;).

If you activate the debug logs
on org.apache.activemq.store.kahadb.MessageDatabase you should see several
messages and a "Checkpoint started." or another "gc candidates after tx
range" showing it tries to cleanup *unused* files (completed).




Romain Manni-Bucau
@rmannibucau <https://twitter.com/rmannibucau> |  Blog
<https://blog-rmannibucau.rhcloud.com> | Old Wordpress Blog
<http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> |
LinkedIn <https://www.linkedin.com/in/rmannibucau> | Tomitriber
<http://www.tomitribe.com> | JavaEE Factory
<https://javaeefactory-rmannibucau.rhcloud.com>

2016-10-06 18:53 GMT+02:00 mean_bcp <go...@versatilets.com>:

> Actually, please ignore the statement about db.data being 6GB and growing,
> I
> got some bad information there.
>
> I am curious about cleaning up the db-xx.log files though, and if I can
> configure that automatically. If not, what are the ramifications of
> cleaning
> them up with a cron job occasionally?
>
> Thanks
>
>
>
> --
> View this message in context: http://tomee-openejb.979440.
> n4.nabble.com/KahaDB-growth-tp4680295p4680305.html
> Sent from the TomEE Users mailing list archive at Nabble.com.
>

Re: KahaDB growth

Posted by mean_bcp <go...@versatilets.com>.
Actually, please ignore the statement about db.data being 6GB and growing, I
got some bad information there.

I am curious about cleaning up the db-xx.log files though, and if I can
configure that automatically. If not, what are the ramifications of cleaning
them up with a cron job occasionally?

Thanks



--
View this message in context: http://tomee-openejb.979440.n4.nabble.com/KahaDB-growth-tp4680295p4680305.html
Sent from the TomEE Users mailing list archive at Nabble.com.

Re: KahaDB growth

Posted by mean_bcp <go...@versatilets.com>.
Thank you.

What I'm looking for is some advice for limiting the size of the files. I am
not sure which options can be used, and what the ramifications are.
Currently my db.data is 6GB and growing - does this mean we are not
processing the messages fast enough, or we are saving them too long, etc. I
am not sure how to interpret or fix this issue. If anyone has experience
with this, I would appreciate a nudge in the right direction.

Also, what is the purpose of the db-xx.log files (I'm assuming some sort of
restore?) and the ramifications of deleting them as a part of an automated
cleanup script? Or can I tweak the kahaDB config to remove them for me?



--
View this message in context: http://tomee-openejb.979440.n4.nabble.com/KahaDB-growth-tp4680295p4680303.html
Sent from the TomEE Users mailing list archive at Nabble.com.

Re: KahaDB growth

Posted by Romain Manni-Bucau <rm...@gmail.com>.
depends the way you configure but if using the uri in tomee.xml i think you
can set it using kahadb.xxxx=xxx in the uri (see
https://github.com/apache/tomee/blob/41cb392c6e3dc63d6792eae88e90c33743255212/container/openejb-core/src/test/java/org/apache/openejb/activemq/KahaDBSupportTest.java#L36
)


Romain Manni-Bucau
@rmannibucau <https://twitter.com/rmannibucau> |  Blog
<https://blog-rmannibucau.rhcloud.com> | Old Wordpress Blog
<http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> |
LinkedIn <https://www.linkedin.com/in/rmannibucau> | Tomitriber
<http://www.tomitribe.com> | JavaEE Factory
<https://javaeefactory-rmannibucau.rhcloud.com>

2016-10-05 20:51 GMT+02:00 mean_bcp <go...@versatilets.com>:

> What configuration options can I use to limit the growth of my kahadb
> files?
>
> It grows over time until we run out of space.
>
> I looked at http://activemq.apache.org/kahadb.html but I am not sure which
> options to choose, especially because we are running 5.10.0. Upgrade to
> 5.14
> is possible, but would like to fully test that first, so if there's
> anything
> I can do in 5.10.0, please let me know.
>
>
>
> --
> View this message in context: http://tomee-openejb.979440.
> n4.nabble.com/KahaDB-growth-tp4680295.html
> Sent from the TomEE Users mailing list archive at Nabble.com.
>