[ZBX-17548] Don't store history in Proxy DB If History storage period is 0 Created: 2020 Apr 03 Updated: 2024 Apr 10 Resolved: 2020 Jun 04 |
|
Status: | Closed |
Project: | ZABBIX BUGS AND ISSUES |
Component/s: | Proxy (P) |
Affects Version/s: | 4.2.8, 4.4.7 |
Fix Version/s: | 5.2.0alpha1, 5.2 (plan) |
Type: | Problem report | Priority: | Trivial |
Reporter: | Dmitrijs Lamberts | Assignee: | Andris Zeila |
Resolution: | Fixed | Votes: | 11 |
Labels: | preprocessing, proxy | ||
Remaining Estimate: | Not Specified | ||
Time Spent: | Not Specified | ||
Original Estimate: | Not Specified |
Issue Links: |
|
||||||||
Team: | |||||||||
Sprint: | Sprint 63 (Apr 2020), Sprint 64 (May 2020), Sprint 65 (Jun 2020) | ||||||||
Story Points: | 1 |
Description |
Time ago we added a possibility to specify History storage period to 0 on master items. That normally return huge amount of data, which is processed by dependent items and after that is not needed at all. So dropping it after pre processing saved a lot of space in our database. If there is such Master item monitored by Proxy, which is returning huge amount of data, despite the fact that History storage period is 0, that value is written to proxy_history and sent to Zabbix server. Which first of all grows the size of proxy database without any proper reason, and most important - heavily utilizes data sender. There is actually no good reason to send this data to Zabbix server, because only way where this data is utilized is preprocessing, but since 4.2 preprocessing is done on Proxy side.
Only thing that suffers is Inventory collection. Inventory is populated even if History storage period is 0. But there is no good reason to populate single inventory field from master item that return huge amount of data. Instead that should be done through dependent items. |
Comments |
Comment by Glebs Ivanovskis [ 2020 Apr 03 ] |
There is ZBXNEXT-5777 which may require more sophisticated logic. |
Comment by Oleksii Zagorskyi [ 2020 Apr 03 ] |
But ... LLD is processed by server only, so it should be send to server anyway. wiper: Yes, but if LLD is based on dependent item, then we don't need the master item on server. |
Comment by Andris Zeila [ 2020 Jun 01 ] |
Released
Note that the storage rules are somewhat complicated. The simplified version - values of non-numeric items (character, text, log value types) with 0 history storage period are not stored in proxy history/sent to server. |
Comment by Aigars Kadikis [ 2020 Jul 08 ] |
The best workaround currently I can imagine on 4.2, 4.4, 5.0 is to execute the Prometheus monitoring from the master server only. If this is not an option, I think, it will require to schedule a daily proxy shutdown to 'truncate table proxy_history; truncate table ids;'. Then start back the proxy. |