Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-18169

housekeeper does not delete history/trends of deleted items if override period is used

    XMLWordPrintable

    Details

    • Team:
      Team A
    • Sprint:
      Sprint 66 (Jul 2020), Sprint 67 (Aug 2020)
    • Story Points:
      1

      Description

      I could not believe it is. But that's true.

      In function we have these lines:

      	for (table = hk_cleanup_tables; NULL != table->name; table++)
      	{
      		if (ZBX_HK_MODE_REGULAR != *table->poption_mode || ZBX_HK_OPTION_ENABLED == *table->poption_global)
      			continue;
      

      Imagine that for some reason I decided to keep less history and/or trends than set per-item level.
      I've just enabled "Override item history/trend period" checkbox(s) and set custom number of days.
      I keep "Enable internal housekeeping" enabled for history/trends, as it was.

      In a result, number of records in "housekeeper" table started to grow.
      Zabbix server executes this SQL to select records for cleanup:

      select housekeeperid,tablename,field,value from housekeeper where tablename in ('events') order by tablename
      

      Why is this so?
      How history/trends of deleted items is different from history/trends of existing items?
      Why for deleted ones it's preserved but for existing ones it's cleaned up ?

      I'm pretty sure this is regression.
      If it's by design - it's absolutely not clear for user why such logic is used.

      As I see this logic has been changed in version 4.2.
      4.0 was fine in this regard.

        Attachments

          Activity

            People

            Assignee:
            vso Vladislavs Sokurenko
            Reporter:
            zalex_ua Oleksii Zagorskyi
            Votes:
            1 Vote for this issue
            Watchers:
            6 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: