Bug 2230431

Summary: The `sar -B` reports '%vmeff' beyond 100
Product: Red Hat Enterprise Linux 9 Reporter: Abdul Rehman Quadri <aquadri>
Component: sysstatAssignee: Lukáš Zaoral <lzaoral>
Status: CLOSED MIGRATED QA Contact: qe-baseos-daemons
Severity: low Docs Contact: Šárka Jana <sjanderk>
Priority: unspecified    
Version: 9.0CC: gfialova, jgalipea, sjanderk
Target Milestone: rcKeywords: MigratedToJIRA
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Known Issue
Doc Text:
.The `%vmeff` metric from the `sysstat` package displays incorrect values The `sysstat` package provides the `%vmeff` metric to measure the page reclaim efficiency. The values of the `%vmeff` column returned by the `sar -B` command are incorrect because `sysstat` does not parse all relevant `/proc/vmstat` values provided by later kernel versions. To work around this problem, you can calculate the `%vmeff` value manually from the `/proc/vmstat` file. For details, see link:https://access.redhat.com/solutions/7027076[Why the `sar(1)` tool reports `%vmeff` values beyond 100 % in RHEL 8 and RHEL 9?]
Story Points: ---
Clone Of: Environment:
Last Closed: 2023-10-06 16:36:13 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Abdul Rehman Quadri 2023-08-09 12:29:00 UTC
Description of problem:
The `sar -B` commands report the paging statistics where the output
includes '%vmeff' column.
The `%vmeff` as per the man page is [pgsteal / pgscan].

Version-Release number of selected component (if applicable):
sysstat-12.5.4-5.el9.x86_64

How reproducible:
Always

Steps to Reproduce:
1. Stress the system for memory utilization so that the cache is reclaimed & swapping occurs.
2. sar -B
3. And look for the `%vmeff` column.

Actual result:
# sar -B 1
Linux 5.14.0-284.25.1.el9_2.x86_64 (9rhel) 	08/09/2023 	_x86_64_	(1 CPU)

04:36:26 PM  pgpgin/s pgpgout/s   fault/s  majflt/s  pgfree/s pgscank/s pgscand/s pgsteal/s    %vmeff
04:36:27 PM      0.00      0.00      0.00      0.00      0.00      0.00      0.00      0.00      0.00
04:36:28 PM      0.00      0.00      0.00      0.00      4.00      0.00      0.00      0.00      0.00
04:36:29 PM      0.00      0.00      0.00      0.00      1.00      0.00      0.00      0.00      0.00
04:36:30 PM    491.09 105586.14  60935.64      4.95  57935.64 239636.63   9034.65  94788.12     38.12
04:36:31 PM  12310.00 538256.00  80468.00    133.00  92348.00 204523.00  43644.00 164542.00     66.30
04:36:32 PM   1031.67 167920.00  74993.75     13.33  79612.08 172162.08  15215.00 149747.50     79.92
04:36:34 PM    994.29 499363.81 122150.48     19.05 138315.24 319519.05  70208.57 251845.71     64.62
04:36:35 PM  13865.26 254842.11  21938.95    441.05  48472.63 131057.89  11048.42  81572.63     57.40
04:36:36 PM 153948.62 129625.69  43133.03   4892.66  45727.52 109327.52      0.00  69844.04     63.89
04:36:37 PM  72123.08      9.89  19817.58   2248.35  17915.38  10175.82      0.00  20351.65    200.00  <<-----
04:36:38 PM  29152.00      0.00   8227.00    919.00   7413.00   7411.00      0.00  14806.00    199.78  <<-----
04:36:39 PM 105044.25 205497.35  29342.48   3339.82  37755.75 151597.35      0.00  62493.81     41.22
04:36:40 PM 107365.52      0.00  29221.84   3340.23  19342.53  19228.74      0.00  38340.23    199.39  <<----- 
04:36:41 PM 399295.05 348940.59 111702.97  12735.64 106972.28 246384.16      0.00 200459.41     81.36
04:36:42 PM 322668.00 339464.00  89742.00  10247.00  93473.00 273802.00      0.00 170922.00     62.43
04:36:43 PM 408888.00 380136.00 113442.00  12926.00 105087.00 276010.00      0.00 194792.00     70.57
04:36:44 PM 390824.00 389380.00 108543.00  12304.00 107732.00 311288.00      0.00 198284.00     63.70
04:36:46 PM 109600.00 248129.17  30189.06   3431.77  45426.56 148714.06      0.00  76365.62     51.35
04:36:47 PM  70936.00      0.00  19666.00   2239.00     31.00      0.00      0.00     44.00      0.00
04:36:48 PM 108696.00      0.00  30310.00   3477.00  24087.00  24083.00      0.00  48148.00    199.93  <<-----


Expected result:
The value of %vmeff should be <=100%


Additional info:
The Bugzilla has already been raised for RHEL 8[1] and it was identified that the changes in the /proc/vmstat fields caused this issue. The issue has been raised to upstream[2].

Raising this Bugzilla to track for RHEL9.

[1] https://bugzilla.redhat.com/show_bug.cgi?id=2228949
[2] https://github.com/sysstat/sysstat/issues/343#issuecomment-1667640798

Comment 3 RHEL Program Management 2023-10-06 16:35:51 UTC
Issue migration from Bugzilla to Jira is in process at this time. This will be the last message in Jira copied from the Bugzilla bug.

Comment 4 RHEL Program Management 2023-10-06 16:36:13 UTC
This BZ has been automatically migrated to the issues.redhat.com Red Hat Issue Tracker. All future work related to this report will be managed there.

Due to differences in account names between systems, some fields were not replicated.  Be sure to add yourself to Jira issue's "Watchers" field to continue receiving updates and add others to the "Need Info From" field to continue requesting information.

To find the migrated issue, look in the "Links" section for a direct link to the new issue location. The issue key will have an icon of 2 footprints next to it, and begin with "RHEL-" followed by an integer.  You can also find this issue by visiting https://issues.redhat.com/issues/?jql= and searching the "Bugzilla Bug" field for this BZ's number, e.g. a search like:

"Bugzilla Bug" = 1234567

In the event you have trouble locating or viewing this issue, you can file an issue by sending mail to rh-issues. You can also visit https://access.redhat.com/articles/7032570 for general account information.