RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1764748 - pcp atopsar ignores 'samples' count
Summary: pcp atopsar ignores 'samples' count
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: pcp
Version: 7.8
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: rc
: 7.9
Assignee: Nathan Scott
QA Contact: Jan Kurik
URL:
Whiteboard:
Depends On:
Blocks: 1782202
TreeView+ depends on / blocked
 
Reported: 2019-10-23 17:19 UTC by Charles Haithcock
Modified: 2021-08-27 22:42 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: No Doc Update
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-09-29 19:24:55 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2020:3869 0 None None None 2020-09-29 19:25:25 UTC

Description Charles Haithcock 2019-10-23 17:19:01 UTC
Description of problem:


When providing the samples argument, the samples argument is ignored:


 r7 # pcp atopsar 1 1

r7  3.10.0-1062.4.1.el7.x86_64  #1 SMP Wed Sep 25 09:42:57 EDT 2019  x86_64  2019/10/23

-------------------------- analysis date: 2019/10/23 --------------------------

13:16:29  cpu  %usr %nice %sys %irq %softirq  %steal %guest  %wait %idle  _cpu_
13:16:30  all     1     0    2    0        0       0      0      0   197
            0     1     0    1    0        1       0      0      0    97
            1     0     0    0    0        0       0      0      0   100
13:16:31  all     3     0    4    0        0       0      0      0   193
            0     2     0    5    0        0       0      0      0    93
            1     1     0    0    0        0       0      0      0    99
13:16:32  all     2     0    4    0        0       0      0      0   194
            0     1     0    3    0        0       0      0      0    96
            1     0     0    0    0        0       0      0      0   100
^C


Version-Release number of selected component (if applicable):

 r7 # rpm -q pcp
pcp-4.3.2-3.el7_7.x86_64



How reproducible:

100%


Steps to Reproduce:
1. run a pcp atopsar command with both a sample and interval
2.
3.

Actual results:

pcp atopsar runs as if ignoring the samples argument


Expected results:

'samples' amount of samples are printed and then pcp atopsar terminates. 



Additional info:

Comment 2 Nathan Scott 2019-10-28 15:31:11 UTC
This is now fixed upstream (will be in upstream pcp-5.0.1), can be back-ported during next RHEL7 devel phase.

commit 2ab1cf5d1e547f991c64dde97749a666c045fc25
Author: Nathan Scott <nathans>
Date:   Tue Oct 29 02:28:10 2019 +1100

    pcp-atopsar: fix mishandling of some command line arguments
    
    Cleanup several aspects of command line handling in pcp-atopsar,
    and resolve a reported bug where the samples argument was not
    honoured due to shadowing of a same-named variable with atop.
    
    Resolves Red Hat BZ 1764748.

Comment 6 errata-xmlrpc 2020-09-29 19:24:55 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Low: pcp security, bug fix, and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2020:3869


Note You need to log in before you can comment on or make changes to this bug.