[ZBX-18996] agent on Solaris - "pavailable" value does not include ZFS pool Created: 2021 Feb 09 Updated: 2024 Apr 10 Resolved: 2023 Jan 19 |
|
Status: | Closed |
Project: | ZABBIX BUGS AND ISSUES |
Component/s: | Agent (G) |
Affects Version/s: | 5.2.4 |
Fix Version/s: | None |
Type: | Problem report | Priority: | Major |
Reporter: | Oleksii Zagorskyi | Assignee: | Zabbix Development Team |
Resolution: | Cannot Reproduce | Votes: | 1 |
Labels: | solaris | ||
Remaining Estimate: | Not Specified | ||
Time Spent: | Not Specified | ||
Original Estimate: | Not Specified |
Issue Links: |
|
||||
Team: | |||||
Sprint: | Sprint 74 (Mar 2021), Sprint 75 (Apr 2021), Sprint 76 (May 2021), Sprint 77 (Jun 2021), Sprint 78 (Jul 2021), Sprint 79 (Aug 2021), Sprint 80 (Sep 2021), Sprint 81 (Oct 2021), Sprint 82 (Nov 2021), Sprint 83 (Dec 2021), Sprint 84 (Jan 2022), Sprint 85 (Feb 2022), Sprint 86 (Mar 2022), Sprint 87 (Apr 2022), Sprint 88 (May 2022), Sprint 89 (Jun 2022), Sprint 90 (Jul 2022), Sprint 91 (Aug 2022), Sprint 92 (Sep 2022), Sprint 93 (Oct 2022), Sprint 94 (Nov 2022), Sprint 95 (Dec 2022), Sprint 96 (Jan 2023) |
Description |
On the newer versions of the Solaris server the pavailable value should include the ZFS pool to give the actual memory available percentage However the zabbix agent on the server is not showing the pavailable value as expected. #:~> zabbix_get -s host.com -k 'agent.version' 4.0.16 #:~> zabbix_get -s host.com -k 'vm.memory.size[pavailable]' 6.083881 Where this is the actual available percentage value on the server $ mdb=$(echo "::memstat" | sudo -u zabbix sudo mdb -k); zfs=$(echo "$mdb" | gawk -F "[ %]+" '/^ZFS/{print $4}') $ free=$(echo "$mdb" | gawk -F "[ %]+" '/^Free [^\(]/ \{print $4}'); echo "$zfs+$free" | bc 93.2 Below are some of the pointers why with Solaris 11 onwards we should include the memory consumption by ZFS pool in the pavailable value https://community.oracle.com/tech/apps-infra/discussion/3867433/memory-management-between-zfs-and-applications-in-oracle-solaris-11-x-doc-id-1663862-1 |
Comments |
Comment by Oleksii Zagorskyi [ 2021 Feb 09 ] |
Maybe ZBXNEXT-1360 is related. |
Comment by Andris Mednis [ 2021 Mar 12 ] |
In ZBXNEXT-1360 it is proposed to use "kstat zfs:0:arcstats:size" for getting how much memory is used by ZFS. # echo "::memstat" | mdb -k Usage Type/Subtype Pages Bytes %Tot %Tot/%Subt ---------------------------- ---------------- -------- ----- ----------- Kernel 208734 815.3m 19.9% ZFS 465634 1.7g 44.4% User/Anon 227155 887.3m 21.6% Exec and libs 3944 15.4m 0.3% Page Cache 34904 136.3m 3.3% Free (cachelist) 29647 115.8m 2.8% Free 78445 306.4m 7.4% Total 1048463 3.9g 100% # kstat zfs:0:arcstats:size module: zfs instance: 0 name: arcstats class: misc size 1745465600 The 'mdb' command shows ZFS as taking 465634 pages * 4096 = 1907236864 bytes = 1.776 GB. Would it be the right solution to use only "kstat zfs:0:arcstats:size" for getting ZFS memory use? Or we need to take into account also other metrics which might be relevant, like: # kstat zfs:0:arcstats module: zfs instance: 0 name: arcstats class: misc buf_size 21743352 c 3220878336 c_max 3220878336 c_min 67108864 ... data_freed 1123713472 data_size 1752193792 ... meta_limit 0 meta_max 62971176 meta_used 62971176 ... other_size 40172096 p 201304896 ... prefetch_size 144670720 rawdata_size 0 size 1752193792 ...
|