Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
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.
Description of problem:
Hello,
I'm trying to strart the kvm on my machine and get the following error:
# virsh start <KVM-host>
error: internal error: process exited while connecting to monitor: qemu_madvise: Invalid argument
madvise doesn't support MADV_DONTDUMP, but dump_guest_core=off specified
2017-10-07T22:22:04.731784Z qemu-kvm: -object memory-backend-file,id=ram-node0,prealloc=yes,mem-path=/dev/hugepages/libvirt/qemu/2-ls3059v1,size=387352363008,host-nodes=0,policy=bind: cannot bind memory to host NUMA nodes: Invalid argument
Version-Release number of selected component (if applicable):
I'm using qemu-kvm-rhev 2.6.0-28.el7_3.12
Please help me to change the configuration or fix the bug ASAP. SAP is waiting for solution.
Thanks and best regards,
Motahareh Kardeh
Red Hat Software Engineer @ SAP LinuxLab
Email: mkardeh
Phone : +49 6227 761645
Hi,
the following part of the code has raised the error:
exec.c
------------------------------------------------------------------------
+static void qemu_ram_setup_dump(void *addr, ram_addr_t size)
+{
+ int ret;
+ QemuOpts *machine_opts;
+
+ /* Use MADV_DONTDUMP, if user doesn't want the guest memory in the core */
+ machine_opts = qemu_opts_find(qemu_find_opts("machine"), 0);
+ if (machine_opts &&
+ !qemu_opt_get_bool(machine_opts, "dump-guest-core", true)) {
+ ret = madvise(addr, size, MADV_DONTDUMP);
+ if (ret) {
+ perror("qemu_madvise");
+ fprintf(stderr, "madvise doesn't support MADV_DONTDUMP, "
+ "but dump_guest_core=off specified\n");
+ }
+ }
+}
------------------------------------------------------------------------
Please also review and comment the function madvise_behavior_valid(int behavior) and send me the link to the unit test.
I think the bug is caused by missing documentation/wrong understanding or wrong implementation.
BR, Mota
Please provide the version of RHEL running on the host. Is it RHEL 7.3?
In particular, what is the host kernel version?
For completeness, please also provide the libvirt XML for this VM and the libvirt version. Thanks.
Yes, they are both RHEL 7.3.
Host and VM kernel versions are:
3.10.0-514.32.2.el7.x86_64 #1 SMP Mon Sep 11 05:36:21 EDT 2017 x86_64 x86_64 x86_64 GNU/Linux
# libvirtd --version
libvirtd (libvirt) 3.2.0
I attached to the Bug the XML for VM:
XML_KVM_for_SAP_Performance_testing
More Info:
I'm using the following qemu versions:
- qemu-img-rhev 2.6.0-28.el7_3.12
- qemu-kvm-common-rhev 2.6.0-28.el7_3.12
- qemu-kvm-rhev 2.6.0-28.el7_3.12
- qemu-kvm-tools-rhev 2.6.0-28.el7_3.12
Thanks,
BR, Mota
Hi Mota,
> memory-backend-file,id=ram-node0,prealloc=yes,mem-path=/dev/hugepages/
> libvirt/qemu/2-ls3059v1,size=387352363008,host-nodes=0,policy=bind: cannot
> bind memory to host NUMA nodes: Invalid argument
as already discussed in email, this error probably is related to your cmdline setting for disabling memory cgroups. As such the NUMA pinning can't be applied correctly.
Please remove the setting
cgroup_disable=memory
from your kernel cmdline and try starting the VM again.
Thanks!
Martin
(In reply to Martin Tessun from comment #6)
> Hi Mota,
>
> > memory-backend-file,id=ram-node0,prealloc=yes,mem-path=/dev/hugepages/
> > libvirt/qemu/2-ls3059v1,size=387352363008,host-nodes=0,policy=bind: cannot
> > bind memory to host NUMA nodes: Invalid argument
>
> as already discussed in email, this error probably is related to your
> cmdline setting for disabling memory cgroups. As such the NUMA pinning can't
> be applied correctly.
>
> Please remove the setting
> cgroup_disable=memory
> from your kernel cmdline and try starting the VM again.
>
> Thanks!
> Martin
After doing the math correctly the error is quite obvious:
1. We have 1GB hugepages defined
2. We align 1443GB to a total of 4 Numa Nodes
3. As we distribute equally, we end up with 360.75GB per Numa Node.
So increasing the memory by 1GB and adjusting the NUMA Node memory to 361GB per cell, got the machine starting. So at least the last message could be solved this way and the VM does start now.
Hi All,
first of all my special thanks to Martin Tessun. He did a great job, great to have you in the team.
After Martin has changed the NUMA configuration as he described, the VM is on running again and I can continue with the Performance testing.
We will adjust the "SAP HANA on KVM: Best Practices Resource Guide".
Thanks and best regards,
Mota