Ad Widget

Collapse

History_unit and history_text tables and problem with graphics with old data

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • esf982
    Junior Member
    • Jan 2020
    • 16

    #1

    History_unit and history_text tables and problem with graphics with old data

    Hi, I need to decrease the size of my database that is over 300GB with 6 months of use.
    I have about 500 hosts, I have already read several tutorials and documentation, I have made several changes such as increasing the checking time, I reduced the history to 7 days, the trends I left with 365 because it is the most important for me (graphics).

    I have already activated housekeeping, which runs every 1 hour and set to 0 to have no limit during the exclusion (aware of the risks).

    1. My question is, can I perform a truncate on the history_text or history_unit tables WITHOUT losing the data in the graphs? Or is there a way to decrease the base size without losing the information displayed via zabbix graphics? I understood that the data comes from trends, so we can keep it for a longer period, but I don't know where the data used in the graphs is collected from and the impact of executing what I'm asking.


    2. Can I force the graphics generation again? I think our dba did something wrong in the zabbix database, I have 120gb of data in the history tables but less than 100mb in the trends table. My graphs don't show old values, just recent ones
    When I see only the values ​​via the zabbix web interface, the data is there but it is not displayed as graphs, only the data for this week after restoring the base, this occurs with all hosts and items, any period. My database has 6 months of data but graphs only show data for a week

    I'm using Zabbix 4.4, with mariadb version 5.5.64 in Innodb, with CentOS 7 x64.
    I have easy access to DBA consultants, but they don't know how Zabbix works so I need to guide them on what should be done, "how to do it" is up to them.
  • esf982
    Junior Member
    • Jan 2020
    • 16

    #2
    Click image for larger version

Name:	Zabbix1.png
Views:	1871
Size:	121.4 KB
ID:	402419

    Click image for larger version

Name:	Zabbix2.png
Views:	1900
Size:	94.8 KB
ID:	402420

    Comment

    • esf982
      Junior Member
      • Jan 2020
      • 16

      #3
      Old data is not shown in the charts, just as values.

      Comment

      • Atsushi
        Senior Member
        • Aug 2013
        • 2028

        #4
        Trend data is used when displaying graphs for past hours or long periods. Isn't it still in the history, but not in the trend?

        Comment

        • esf982
          Junior Member
          • Jan 2020
          • 16

          #5
          Originally posted by Atsushi
          Trend data is used when displaying graphs for past hours or long periods. Isn't it still in the history, but not in the trend?
          Hi,

          New and old data are in history, but the graphs only contain data from a week, as if I didn't have them in the trends table.

          My trends table is 98MB, and trends_unit is 151MB.
          My history table is 85GB, history_text is 119GB and history_unit is 98GB.

          Does it make sense that I have such a small trend table for this volume of data in history?

          Is there a way to force the generation of graphics based on my history?

          Comment

          • aib
            Senior Member
            • Jan 2014
            • 1615

            #6
            Copy-paste from https://www.zabbix.com/documentation...ory_and_trends
            History tables do not participate in trend generation in any way.
            Sincerely yours,
            Aleksey

            Comment

            • esf982
              Junior Member
              • Jan 2020
              • 16

              #7
              Originally posted by aib
              Okay, thanks for the info. We truncated the history * tables and the graphs were not really affected, only recent data that came from the history.

              Comment

              Working...