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.

Bug 1160997

Summary: RDMA based live guest migration failed if using --rdma-pin-all
Product: Red Hat Enterprise Linux 7 Reporter: zhe peng <zpeng>
Component: libvirtAssignee: Jiri Denemark <jdenemar>
Status: CLOSED NOTABUG QA Contact: Virtualization Bugs <virt-bugs>
Severity: medium Docs Contact:
Priority: medium    
Version: 7.1CC: dyuan, honzhang, jmiao, mzhan, rbalakri, zhwang
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-11-10 16:05:03 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:
Attachments:
Description Flags
source qemu log
none
souce libvirtd log
none
target qemu log none

Description zhe peng 2014-11-06 05:45:23 UTC
Description of problem:
RDMA based live guest migration failed with --rdma-pin-all option.

Version-Release number of selected component (if applicable):
libvirt-1.2.8-5.el7.x86_64
qemu-kvm-rhev-2.1.2-3.el7.x86_64

How reproducible:
always


Steps to Reproduce:
1.prepare rdma based migration env.
2.config rdma support in qemu.conf & libvirtd.conf
3.load module.
4.do migration with --rdma-pin-all option.

# virsh migrate --live --rdma-pin-all --migrateuri rdma://192.168.100.2 rhel7 --listen-address 0 qemu+ssh://192.168.100.2/system --verbose 
error: operation failed: migration job: unexpectedly failed

Actual results:
got error,in /var/log/libvirt/qemu/$guest.xml

source_resolve_host RDMA Device opened: kernel name mlx4_0 uverbs device name uverbs0, infiniband_verbs class device path /sys/class/infiniband_verbs/uverbs0, infiniband class device path /sys/class/infiniband/mlx4_0, transport: (2) Ethernet
Failed to register local dest ram block!
: Cannot allocate memory
RDMA ERROR: receiving remote info!


Expected results:
work well.

Additional info:

Comment 1 zhe peng 2014-11-06 05:47:36 UTC
Created attachment 954317 [details]
source qemu log

Comment 2 zhe peng 2014-11-06 05:48:14 UTC
Created attachment 954318 [details]
souce libvirtd log

Comment 3 zhe peng 2014-11-06 05:48:57 UTC
Created attachment 954319 [details]
target qemu log

Comment 5 Jiri Denemark 2014-11-10 16:05:03 UTC
The relevant part of domain XML is:

  <memory unit='KiB'>1048576</memory>
  <memtune>
    <hard_limit unit='KiB'>1048576</hard_limit>
  </memtune>

The hard limit is just too low, remember that both guest memory and any memory consumed by QEMU itself has to fit within the limit, otherwise the domain will be killed sooner or later even without any migration or rdma-pin-all.

Comment 6 Jiri Denemark 2014-11-10 16:08:01 UTC
Oops, I didn't really want to change the summary...

Comment 7 zhe peng 2014-11-11 03:19:53 UTC
Got it , thanks.
I update xml to:
....
<memtune>
    <hard_limit unit='KiB'>2097152</hard_limit>
    <swap_hard_limit unit='KiB'>2097152</swap_hard_limit>
  </memtune>
....

then do migration:
# virsh migrate --live --rdma-pin-all --migrateuri rdma://192.168.100.2 rhel7 --listen-address 0 qemu+ssh://192.168.100.2/system --verbose 
Migration: [100 %]

migration worked well with --rdma-pin-all, thanks your explain.