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 748689 - calling get_node_cpu_stats() return errors:code: 1, message: internal error nparams too large
Summary: calling get_node_cpu_stats() return errors:code: 1, message: internal error n...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: perl-Sys-Virt
Version: 6.3
Hardware: All
OS: Linux
medium
medium
Target Milestone: rc
: ---
Assignee: Daniel Berrangé
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-10-25 04:05 UTC by Gunannan Ren
Modified: 2012-06-20 12:00 UTC (History)
10 users (show)

Fixed In Version: perl-Sys-Virt-0.9.9-1.el6
Doc Type: Bug Fix
Doc Text:
No technical notes required
Clone Of:
Environment:
Last Closed: 2012-06-20 12:00:45 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2012:0754 0 normal SHIPPED_LIVE perl-Sys-Virt bug fix and enhancement update 2012-06-19 19:31:07 UTC

Description Gunannan Ren 2011-10-25 04:05:47 UTC
Description of problem:
Calling get_node_cpu_stats binding function returns error message, but not to virsh command. Errors as follows:

libvirt error code: 1, message: internal error nparams too large

The producing codes:

use strict;
use warnings;

use Sys::Virt;

my $con = Sys::Virt->new(address => "qemu:///system", readonly => 0);
$con->get_node_cpu_stats();


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


How reproducible:

always

Steps to Reproduce:
1. run the above perl codes.
2.
3.
  
Actual results:
report error message.

Expected results:
return correct node cpu stats.

Additional info:

Comment 1 Gunannan Ren 2011-10-25 04:09:12 UTC
perl-Sys-Virt and libvirt version:

perl-Sys-Virt-0.9.4-2.el6.x86_64
libvirt-client-0.9.4-19.el6.x86_64
libvirt-0.9.4-19.el6.x86_64

Comment 3 Gunannan Ren 2011-10-25 06:20:53 UTC
When I test get_node_memory_stats(), the error message is the same.
"libvirt error code: 1, message: internal error nparams too large"
So update a comment for this.

Comment 4 Alex Jia 2011-10-25 07:41:58 UTC
It should be a libvirt issue, libvirt defines the following $macro in remote_protocol.h, and when nparams > $macro, we will meet previous errors:

./src/remote/remote_protocol.h:55:#define REMOTE_NODE_CPU_STATS_MAX 16
./src/remote/remote_protocol.h:56:#define REMOTE_NODE_MEMORY_STATS_MAX 16
./src/remote/remote_protocol.h:61:#define REMOTE_DOMAIN_MEMORY_STATS_MAX 1024

length '16' is too small, maybe, we should change the above '16' to '1024' like REMOTE_DOMAIN_MEMORY_STATS_MAX. 

Alex

Comment 5 Alex Jia 2011-10-25 08:16:46 UTC
I just saw libvirt and perl-sys-virt codes again, as the value of @nparams is dynamic, call the API setting @nparams to 0 and @params as NULL, in other words, $con->get_node_cpu_stats() should give a default @nparams as 0 and @params as NULL like funciton cmdNodeCpuStats in tools/virsh.c.

Mybe, libvirt should do these work rather than pushing them to upper layer application such as virsh command, perl or python binding, otherwise, each application both need to add some check function or pass some default values.

Alex

Comment 8 Daniel Berrangé 2012-01-09 16:46:10 UTC
I can't reproduce this problem. Can you confirm that you still see an error when testing this with libvirt 0.9.9 ?

Comment 9 Alex Jia 2012-01-10 03:01:39 UTC
perl-Sys-Virt-0.9.9-1 is okay for me.

Comment 10 Gunannan Ren 2012-01-10 08:04:25 UTC
It's ok, The bug has been verified on
libvirt-0.9.9-1.el6.x86_64
libvirt-devel-0.9.9-1.el6.x86_64
libvirt-client-0.9.9-1.el6.x86_64
perl-Sys-Virt-0.9.9-1.el6.x86_64

Comment 12 Daniel Berrangé 2012-05-01 09:05:20 UTC
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
No technical notes required

Comment 14 errata-xmlrpc 2012-06-20 12:00:45 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, and where to find the updated
files, follow the link below.

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

http://rhn.redhat.com/errata/RHBA-2012-0754.html


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