# Truncate "icinga\_notification" table

**URL:** <https://community.icinga.com/t/truncate-icinga-notification-table/10910>\
**Category:** Icinga 2\
**Tags:** mysql, ido\
**Created:** [October 27, 2022, 1:29am UTC](https://community.icinga.com/t/truncate-icinga-notification-table/10910 "2022-10-27T01:29:47Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![monigacom](https://community.icinga.com/letter_avatar_proxy/v4/letter/m/bb73d2/32.png) [@monigacom](https://community.icinga.com/u/monigacom)\
**Post date:** [October 27, 2022, 1:29am UTC](https://community.icinga.com/t/truncate-icinga-notification-table/10910/1 "2022-10-27T01:29:48Z")

</div>

Hi,

This table is like 20GB including the index. The IDO 'cleanup" never had it so it just pileup. I think a manual limited size cleanup is required and not to overwhelm the day today operation.

Can someone advise how to do that in steps/phases? I would like to keep the last 60 days history and then add it in the IDO “cleanup” later.

Thanks

---

<div class="post-metadata">

**Author:** ![moreamazingnick](https://community.icinga.com/user_avatar/community.icinga.com/moreamazingnick/32/7725_2.png) [@moreamazingnick](https://community.icinga.com/u/moreamazingnick)\
**Post date:** [October 27, 2022, 7:59am UTC](https://community.icinga.com/t/truncate-icinga-notification-table/10910/2 "2022-10-27T07:59:27Z")

</div>

How does your IdoMysqlConnection object look like?  
[Ido Example](https://icinga.com/docs/icinga-2/latest/doc/14-features/#db-ido-cleanup)  
[Ido Documentation](https://icinga.com/docs/icinga-2/latest/doc/09-object-types/#idomysqlconnection)  
did you set a notifications\_age?

---

<div class="post-metadata">

**Author:** ![monigacom](https://community.icinga.com/letter_avatar_proxy/v4/letter/m/bb73d2/32.png) [@monigacom](https://community.icinga.com/u/monigacom)\
**Post date:** [October 27, 2022, 1:55pm UTC](https://community.icinga.com/t/truncate-icinga-notification-table/10910/3 "2022-10-27T13:55:01Z")

</div>

No there is no “notification\_age” in the “cleanup”.

---

<div class="post-metadata">

**Author:** ![moreamazingnick](https://community.icinga.com/user_avatar/community.icinga.com/moreamazingnick/32/7725_2.png) [@moreamazingnick](https://community.icinga.com/u/moreamazingnick)\
**Post date:** [October 27, 2022, 9:05pm UTC](https://community.icinga.com/t/truncate-icinga-notification-table/10910/4 "2022-10-27T21:05:28Z")

</div>

well than edit the ido config and set the notification\_age retention policy to a timespan you consider reasonable. without that there is no cleanup

---

<div class="post-metadata">

**Author:** ![monigacom](https://community.icinga.com/letter_avatar_proxy/v4/letter/m/bb73d2/32.png) [@monigacom](https://community.icinga.com/u/monigacom)\
**Post date:** [October 28, 2022, 1:31am UTC](https://community.icinga.com/t/truncate-icinga-notification-table/10910/5 "2022-10-28T01:31:34Z")

</div>

I think and afraid of If I do that, the DB going to get busy which I might impact the normal operation. That’s why I’m looking for an option to delete the history manually up to a certain point at least.

---

<div class="post-metadata">

**Author:** ![rsx](https://community.icinga.com/user_avatar/community.icinga.com/rsx/32/2094_2.png) [@rsx](https://community.icinga.com/u/rsx)\
**Post date:** [October 28, 2022, 8:05am UTC](https://community.icinga.com/t/truncate-icinga-notification-table/10910/6 "2022-10-28T08:05:28Z")

</div>

I totally agree to not activate this option now. [Here](https://github.com/Icinga/icinga2/issues/8817) you’ll find some more information about this and [here](https://gist.github.com/lazyfrosch/6881834) the author has created a suitable tool. Do to lack of time I’ve not been testing it.

---

<div class="post-metadata">

**Author:** ![monigacom](https://community.icinga.com/letter_avatar_proxy/v4/letter/m/bb73d2/32.png) [@monigacom](https://community.icinga.com/u/monigacom)\
**Post date:** [October 28, 2022, 2:53pm UTC](https://community.icinga.com/t/truncate-icinga-notification-table/10910/7 "2022-10-28T14:53:46Z")

</div>

Thank you for sharing that information. Much appreciated!
