virt-manager PCI passthrough gives error “No IOMMU Found” even w/ Intel IOMMU enabled [closed]

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
2
down vote

favorite












I am trying to set up PCI passthrough in virt-manager to grant my Debian Wheezy guest VM access to my laptop's Intel Centrino N wireless card.



The Debian default kernel has Intel IOMMU enabled, and I have passed intel_iommu=on to the kernel at boot (by editing /etc/default/grub and setting GRUB_CMDLINE_LINUX="intel_iommu=on", and then running grub-update) ...



Looking at dmesg to verify that IOMMU is indeed enabled, I see: [ 0.000000] Intel-IOMMU: enabled ...



I tried following the instructions here, and used virsh to detach the PCI device before adding it to the VM (i.e. virsh nodedev-detach pci_0000_01_00_0) just to be sure.



However, I cannot boot into the guest VM at all with PCI passthrough enabled for this wireless card, and I am getting the following error (from /var/log/libvirt/libvirtd.log):



2014-09-22 04:45:19.325+0000: 2990: error : qemuMonitorOpenUnix:305 : failed to connect to monitor socket: No such process
2014-09-22 04:45:19.325+0000: 2990: error : qemuProcessWaitForMonitor:1593 : internal error process exited while connecting to monitor: char device redirected to /dev/pts/1
**No IOMMU found. Unable to assign device "hostdev0"
kvm: -device pci-assign,host=01:00.0,id=hostdev0,configfd=22,bus=pci.0,addr=0x7: Device 'pci-assign' could not be initialized**


Here is the full output from /var/log/libvirt/qemu/:



2014-09-22 04:10:47.002+0000: starting up
LC_ALL=C PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin HOME=/ QEMU_AUDIO_DRV=none /usr/bin/kvm -S -M pc-1.1 -cpu Nehalem,+rdtscp,+avx,+osxsave,+xsave,+tsc-deadline,+x2apic,+pdcm,+xtpr,+tm2,+est,+vmx,+ds_cpl,+monitor,+dtes64,+pclmuldq,+pbe,+tm,+ht,+ss,+acpi,+ds,+vme -enable-kvm -m 2500 -smp 4,sockets=4,cores=1,threads=1 -name DebianStableSandbox -uuid c18e2808-c98a-2b4d-54f1-00977d3ec1d2 -no-user-config -nodefaults -chardev socket,id=charmonitor,path=/var/lib/libvirt/qemu/DebianStableSandbox.monitor,server,nowait -mon chardev=charmonitor,id=monitor,mode=control -rtc base=utc -no-shutdown -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 -drive file=/var/lib/libvirt/images/DebianNET.img,if=none,id=drive-virtio-disk0,format=raw -device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x5,drive=drive-virtio-disk0,id=virtio-disk0,bootindex=1 -drive if=none,id=drive-ide0-1-0,readonly=on,format=raw -device ide-cd,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 -netdev tap,fd=21,id=hostnet0 -device virtio-net-pci,netdev=hostnet0,id=net0,mac=52:54:00:c5:4a:a9,bus=pci.0,addr=0x3 -chardev pty,id=charserial0 -device isa-serial,chardev=charserial0,id=serial0 -device usb-tablet,id=input0 -vnc 127.0.0.1:0 -vga cirrus -device intel-hda,id=sound0,bus=pci.0,addr=0x4 -device hda-duplex,id=sound0-codec0,bus=sound0.0,cad=0 -device pci-assign,host=01:00.0,id=hostdev0,configfd=22,bus=pci.0,addr=0x7 -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x6
char device redirected to /dev/pts/1
No IOMMU found. Unable to assign device "hostdev0"
kvm: -device pci-assign,host=01:00.0,id=hostdev0,configfd=22,bus=pci.0,addr=0x7: Device 'pci-assign' could not be initialized
2014-09-22 04:10:47.610+0000: shutting down


I think that the "failed to connect to monitor" message is somehow related. If I use virt-manager to add the wireless card as a PCI device, without first detaching it with virsh nodedev-detach (as mentioned above), then I get an error message from virt-manager saying:



Error starting domain: Unable to read from monitor: Connection reset by peer

Traceback (most recent call last):
File "/usr/share/virt-manager/virtManager/asyncjob.py", line 45, in cb_wrapper
callback(asyncjob, *args, **kwargs)
File "/usr/share/virt-manager/virtManager/asyncjob.py", line 66, in tmpcb
callback(*args, **kwargs)
File "/usr/share/virt-manager/virtManager/domain.py", line 1114, in startup
self._backend.create()
File "/usr/lib/python2.7/dist-packages/libvirt.py", line 620, in create
if ret == -1: raise libvirtError ('virDomainCreate() failed', dom=self)
libvirtError: Unable to read from monitor: Connection reset by peer


... and all that shows up in /var/log/libvirt/libvirtd.log in this case is: 2014-09-22 04:48:26.387+0000: 2985: error : qemuMonitorIORead:523 : Unable to read from monitor: Connection reset by peer



In case it is helpful, here is some of the relevant output from lspci -v:



00:00.0 Host bridge: Intel Corporation 2nd Generation Core Processor Family DRAM Controller (rev 09)
Subsystem: Dell Device 04d8
Flags: bus master, fast devsel, latency 0
Capabilities: [e0] Vendor Specific Information: Len=0c <?>
Kernel driver in use: agpgart-intel

00:1c.0 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI Express Root Port 1 (rev b5) (prog-if 00 [Normal decode])
Flags: bus master, fast devsel, latency 0
Bus: primary=00, secondary=01, subordinate=01, sec-latency=0
Memory behind bridge: d1600000-d16fffff
Capabilities: [40] Express Root Port (Slot+), MSI 00
Capabilities: [80] MSI: Enable- Count=1/1 Maskable- 64bit-
Capabilities: [90] Subsystem: Dell Device 04d8
Capabilities: [a0] Power Management version 2
Kernel driver in use: pcieport

01:00.0 Network controller: Intel Corporation Centrino Wireless-N 1030 [Rainbow Peak] (rev 34)
Subsystem: Intel Corporation Centrino Wireless-N 1030 BGN
Flags: fast devsel, IRQ 16
Memory at d1600000 (64-bit, non-prefetchable) [size=8K]
Capabilities: [c8] Power Management version 3
Capabilities: [d0] MSI: Enable- Count=1/1 Maskable- 64bit+
Capabilities: [e0] Express Endpoint, MSI 00
Capabilities: [100] Advanced Error Reporting
Capabilities: [140] Device Serial Number bc-77-37-ff-ff-0d-3f-90
Kernel driver in use: pci-stub


Also, just to be clear, I was able to boot into this VM fine before adding the wireless card as a PCI passthrough device, and once I remove it via virt-manager, everything goes back to working as usual.



Does anyone have any idea how to fix this? Thanks!










share|improve this question















closed as off-topic by sebasth, schily, Jeff Schaller, msp9011, Thomas Sep 3 at 19:07


This question appears to be off-topic. The users who voted to close gave this specific reason:


  • "Questions describing a problem that can't be reproduced and seemingly went away on its own (or went away when a typo was fixed) are off-topic as they are unlikely to help future readers." – sebasth, schily, Jeff Schaller, msp9011, Thomas
If this question can be reworded to fit the rules in the help center, please edit the question.








  • 1




    Are you sure your BIOS really supports IOMMU. The Xen wiki suggests that "there are many buggy BIOSes causing Xen to disable IO virtualization because of errors in the BIOS DMAR/ACPI tables."
    – StrongBad
    Sep 22 '14 at 9:08










  • I am using a Core-i5 2410M processor, and my BIOS is Phoenix SecureCore Tiano ... I can't find any info one way or the other whether this BIOS supports IOMMU or not.
    – J. Taylor
    Sep 24 '14 at 20:13











  • Actually, I just found out that this processor supports VT-x but not VT-d, so I can't do IOMMU.
    – J. Taylor
    Sep 25 '14 at 1:58










  • I want to know if the problem was solved by the author, as if the latest Linux version of the kernel suggested abolishing the KVM_ASSIGN mechanism and supporting only vfio
    – William Levi
    Sep 3 at 8:29










  • @WilliamLevi The problem was solved by the author; he even posted an answer about it. If you read his answer, you will see his solution. Though it may or may not apply to you because your situation is different.
    – Michael Hampton
    Sep 3 at 17:07














up vote
2
down vote

favorite












I am trying to set up PCI passthrough in virt-manager to grant my Debian Wheezy guest VM access to my laptop's Intel Centrino N wireless card.



The Debian default kernel has Intel IOMMU enabled, and I have passed intel_iommu=on to the kernel at boot (by editing /etc/default/grub and setting GRUB_CMDLINE_LINUX="intel_iommu=on", and then running grub-update) ...



Looking at dmesg to verify that IOMMU is indeed enabled, I see: [ 0.000000] Intel-IOMMU: enabled ...



I tried following the instructions here, and used virsh to detach the PCI device before adding it to the VM (i.e. virsh nodedev-detach pci_0000_01_00_0) just to be sure.



However, I cannot boot into the guest VM at all with PCI passthrough enabled for this wireless card, and I am getting the following error (from /var/log/libvirt/libvirtd.log):



2014-09-22 04:45:19.325+0000: 2990: error : qemuMonitorOpenUnix:305 : failed to connect to monitor socket: No such process
2014-09-22 04:45:19.325+0000: 2990: error : qemuProcessWaitForMonitor:1593 : internal error process exited while connecting to monitor: char device redirected to /dev/pts/1
**No IOMMU found. Unable to assign device "hostdev0"
kvm: -device pci-assign,host=01:00.0,id=hostdev0,configfd=22,bus=pci.0,addr=0x7: Device 'pci-assign' could not be initialized**


Here is the full output from /var/log/libvirt/qemu/:



2014-09-22 04:10:47.002+0000: starting up
LC_ALL=C PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin HOME=/ QEMU_AUDIO_DRV=none /usr/bin/kvm -S -M pc-1.1 -cpu Nehalem,+rdtscp,+avx,+osxsave,+xsave,+tsc-deadline,+x2apic,+pdcm,+xtpr,+tm2,+est,+vmx,+ds_cpl,+monitor,+dtes64,+pclmuldq,+pbe,+tm,+ht,+ss,+acpi,+ds,+vme -enable-kvm -m 2500 -smp 4,sockets=4,cores=1,threads=1 -name DebianStableSandbox -uuid c18e2808-c98a-2b4d-54f1-00977d3ec1d2 -no-user-config -nodefaults -chardev socket,id=charmonitor,path=/var/lib/libvirt/qemu/DebianStableSandbox.monitor,server,nowait -mon chardev=charmonitor,id=monitor,mode=control -rtc base=utc -no-shutdown -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 -drive file=/var/lib/libvirt/images/DebianNET.img,if=none,id=drive-virtio-disk0,format=raw -device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x5,drive=drive-virtio-disk0,id=virtio-disk0,bootindex=1 -drive if=none,id=drive-ide0-1-0,readonly=on,format=raw -device ide-cd,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 -netdev tap,fd=21,id=hostnet0 -device virtio-net-pci,netdev=hostnet0,id=net0,mac=52:54:00:c5:4a:a9,bus=pci.0,addr=0x3 -chardev pty,id=charserial0 -device isa-serial,chardev=charserial0,id=serial0 -device usb-tablet,id=input0 -vnc 127.0.0.1:0 -vga cirrus -device intel-hda,id=sound0,bus=pci.0,addr=0x4 -device hda-duplex,id=sound0-codec0,bus=sound0.0,cad=0 -device pci-assign,host=01:00.0,id=hostdev0,configfd=22,bus=pci.0,addr=0x7 -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x6
char device redirected to /dev/pts/1
No IOMMU found. Unable to assign device "hostdev0"
kvm: -device pci-assign,host=01:00.0,id=hostdev0,configfd=22,bus=pci.0,addr=0x7: Device 'pci-assign' could not be initialized
2014-09-22 04:10:47.610+0000: shutting down


I think that the "failed to connect to monitor" message is somehow related. If I use virt-manager to add the wireless card as a PCI device, without first detaching it with virsh nodedev-detach (as mentioned above), then I get an error message from virt-manager saying:



Error starting domain: Unable to read from monitor: Connection reset by peer

Traceback (most recent call last):
File "/usr/share/virt-manager/virtManager/asyncjob.py", line 45, in cb_wrapper
callback(asyncjob, *args, **kwargs)
File "/usr/share/virt-manager/virtManager/asyncjob.py", line 66, in tmpcb
callback(*args, **kwargs)
File "/usr/share/virt-manager/virtManager/domain.py", line 1114, in startup
self._backend.create()
File "/usr/lib/python2.7/dist-packages/libvirt.py", line 620, in create
if ret == -1: raise libvirtError ('virDomainCreate() failed', dom=self)
libvirtError: Unable to read from monitor: Connection reset by peer


... and all that shows up in /var/log/libvirt/libvirtd.log in this case is: 2014-09-22 04:48:26.387+0000: 2985: error : qemuMonitorIORead:523 : Unable to read from monitor: Connection reset by peer



In case it is helpful, here is some of the relevant output from lspci -v:



00:00.0 Host bridge: Intel Corporation 2nd Generation Core Processor Family DRAM Controller (rev 09)
Subsystem: Dell Device 04d8
Flags: bus master, fast devsel, latency 0
Capabilities: [e0] Vendor Specific Information: Len=0c <?>
Kernel driver in use: agpgart-intel

00:1c.0 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI Express Root Port 1 (rev b5) (prog-if 00 [Normal decode])
Flags: bus master, fast devsel, latency 0
Bus: primary=00, secondary=01, subordinate=01, sec-latency=0
Memory behind bridge: d1600000-d16fffff
Capabilities: [40] Express Root Port (Slot+), MSI 00
Capabilities: [80] MSI: Enable- Count=1/1 Maskable- 64bit-
Capabilities: [90] Subsystem: Dell Device 04d8
Capabilities: [a0] Power Management version 2
Kernel driver in use: pcieport

01:00.0 Network controller: Intel Corporation Centrino Wireless-N 1030 [Rainbow Peak] (rev 34)
Subsystem: Intel Corporation Centrino Wireless-N 1030 BGN
Flags: fast devsel, IRQ 16
Memory at d1600000 (64-bit, non-prefetchable) [size=8K]
Capabilities: [c8] Power Management version 3
Capabilities: [d0] MSI: Enable- Count=1/1 Maskable- 64bit+
Capabilities: [e0] Express Endpoint, MSI 00
Capabilities: [100] Advanced Error Reporting
Capabilities: [140] Device Serial Number bc-77-37-ff-ff-0d-3f-90
Kernel driver in use: pci-stub


Also, just to be clear, I was able to boot into this VM fine before adding the wireless card as a PCI passthrough device, and once I remove it via virt-manager, everything goes back to working as usual.



Does anyone have any idea how to fix this? Thanks!










share|improve this question















closed as off-topic by sebasth, schily, Jeff Schaller, msp9011, Thomas Sep 3 at 19:07


This question appears to be off-topic. The users who voted to close gave this specific reason:


  • "Questions describing a problem that can't be reproduced and seemingly went away on its own (or went away when a typo was fixed) are off-topic as they are unlikely to help future readers." – sebasth, schily, Jeff Schaller, msp9011, Thomas
If this question can be reworded to fit the rules in the help center, please edit the question.








  • 1




    Are you sure your BIOS really supports IOMMU. The Xen wiki suggests that "there are many buggy BIOSes causing Xen to disable IO virtualization because of errors in the BIOS DMAR/ACPI tables."
    – StrongBad
    Sep 22 '14 at 9:08










  • I am using a Core-i5 2410M processor, and my BIOS is Phoenix SecureCore Tiano ... I can't find any info one way or the other whether this BIOS supports IOMMU or not.
    – J. Taylor
    Sep 24 '14 at 20:13











  • Actually, I just found out that this processor supports VT-x but not VT-d, so I can't do IOMMU.
    – J. Taylor
    Sep 25 '14 at 1:58










  • I want to know if the problem was solved by the author, as if the latest Linux version of the kernel suggested abolishing the KVM_ASSIGN mechanism and supporting only vfio
    – William Levi
    Sep 3 at 8:29










  • @WilliamLevi The problem was solved by the author; he even posted an answer about it. If you read his answer, you will see his solution. Though it may or may not apply to you because your situation is different.
    – Michael Hampton
    Sep 3 at 17:07












up vote
2
down vote

favorite









up vote
2
down vote

favorite











I am trying to set up PCI passthrough in virt-manager to grant my Debian Wheezy guest VM access to my laptop's Intel Centrino N wireless card.



The Debian default kernel has Intel IOMMU enabled, and I have passed intel_iommu=on to the kernel at boot (by editing /etc/default/grub and setting GRUB_CMDLINE_LINUX="intel_iommu=on", and then running grub-update) ...



Looking at dmesg to verify that IOMMU is indeed enabled, I see: [ 0.000000] Intel-IOMMU: enabled ...



I tried following the instructions here, and used virsh to detach the PCI device before adding it to the VM (i.e. virsh nodedev-detach pci_0000_01_00_0) just to be sure.



However, I cannot boot into the guest VM at all with PCI passthrough enabled for this wireless card, and I am getting the following error (from /var/log/libvirt/libvirtd.log):



2014-09-22 04:45:19.325+0000: 2990: error : qemuMonitorOpenUnix:305 : failed to connect to monitor socket: No such process
2014-09-22 04:45:19.325+0000: 2990: error : qemuProcessWaitForMonitor:1593 : internal error process exited while connecting to monitor: char device redirected to /dev/pts/1
**No IOMMU found. Unable to assign device "hostdev0"
kvm: -device pci-assign,host=01:00.0,id=hostdev0,configfd=22,bus=pci.0,addr=0x7: Device 'pci-assign' could not be initialized**


Here is the full output from /var/log/libvirt/qemu/:



2014-09-22 04:10:47.002+0000: starting up
LC_ALL=C PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin HOME=/ QEMU_AUDIO_DRV=none /usr/bin/kvm -S -M pc-1.1 -cpu Nehalem,+rdtscp,+avx,+osxsave,+xsave,+tsc-deadline,+x2apic,+pdcm,+xtpr,+tm2,+est,+vmx,+ds_cpl,+monitor,+dtes64,+pclmuldq,+pbe,+tm,+ht,+ss,+acpi,+ds,+vme -enable-kvm -m 2500 -smp 4,sockets=4,cores=1,threads=1 -name DebianStableSandbox -uuid c18e2808-c98a-2b4d-54f1-00977d3ec1d2 -no-user-config -nodefaults -chardev socket,id=charmonitor,path=/var/lib/libvirt/qemu/DebianStableSandbox.monitor,server,nowait -mon chardev=charmonitor,id=monitor,mode=control -rtc base=utc -no-shutdown -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 -drive file=/var/lib/libvirt/images/DebianNET.img,if=none,id=drive-virtio-disk0,format=raw -device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x5,drive=drive-virtio-disk0,id=virtio-disk0,bootindex=1 -drive if=none,id=drive-ide0-1-0,readonly=on,format=raw -device ide-cd,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 -netdev tap,fd=21,id=hostnet0 -device virtio-net-pci,netdev=hostnet0,id=net0,mac=52:54:00:c5:4a:a9,bus=pci.0,addr=0x3 -chardev pty,id=charserial0 -device isa-serial,chardev=charserial0,id=serial0 -device usb-tablet,id=input0 -vnc 127.0.0.1:0 -vga cirrus -device intel-hda,id=sound0,bus=pci.0,addr=0x4 -device hda-duplex,id=sound0-codec0,bus=sound0.0,cad=0 -device pci-assign,host=01:00.0,id=hostdev0,configfd=22,bus=pci.0,addr=0x7 -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x6
char device redirected to /dev/pts/1
No IOMMU found. Unable to assign device "hostdev0"
kvm: -device pci-assign,host=01:00.0,id=hostdev0,configfd=22,bus=pci.0,addr=0x7: Device 'pci-assign' could not be initialized
2014-09-22 04:10:47.610+0000: shutting down


I think that the "failed to connect to monitor" message is somehow related. If I use virt-manager to add the wireless card as a PCI device, without first detaching it with virsh nodedev-detach (as mentioned above), then I get an error message from virt-manager saying:



Error starting domain: Unable to read from monitor: Connection reset by peer

Traceback (most recent call last):
File "/usr/share/virt-manager/virtManager/asyncjob.py", line 45, in cb_wrapper
callback(asyncjob, *args, **kwargs)
File "/usr/share/virt-manager/virtManager/asyncjob.py", line 66, in tmpcb
callback(*args, **kwargs)
File "/usr/share/virt-manager/virtManager/domain.py", line 1114, in startup
self._backend.create()
File "/usr/lib/python2.7/dist-packages/libvirt.py", line 620, in create
if ret == -1: raise libvirtError ('virDomainCreate() failed', dom=self)
libvirtError: Unable to read from monitor: Connection reset by peer


... and all that shows up in /var/log/libvirt/libvirtd.log in this case is: 2014-09-22 04:48:26.387+0000: 2985: error : qemuMonitorIORead:523 : Unable to read from monitor: Connection reset by peer



In case it is helpful, here is some of the relevant output from lspci -v:



00:00.0 Host bridge: Intel Corporation 2nd Generation Core Processor Family DRAM Controller (rev 09)
Subsystem: Dell Device 04d8
Flags: bus master, fast devsel, latency 0
Capabilities: [e0] Vendor Specific Information: Len=0c <?>
Kernel driver in use: agpgart-intel

00:1c.0 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI Express Root Port 1 (rev b5) (prog-if 00 [Normal decode])
Flags: bus master, fast devsel, latency 0
Bus: primary=00, secondary=01, subordinate=01, sec-latency=0
Memory behind bridge: d1600000-d16fffff
Capabilities: [40] Express Root Port (Slot+), MSI 00
Capabilities: [80] MSI: Enable- Count=1/1 Maskable- 64bit-
Capabilities: [90] Subsystem: Dell Device 04d8
Capabilities: [a0] Power Management version 2
Kernel driver in use: pcieport

01:00.0 Network controller: Intel Corporation Centrino Wireless-N 1030 [Rainbow Peak] (rev 34)
Subsystem: Intel Corporation Centrino Wireless-N 1030 BGN
Flags: fast devsel, IRQ 16
Memory at d1600000 (64-bit, non-prefetchable) [size=8K]
Capabilities: [c8] Power Management version 3
Capabilities: [d0] MSI: Enable- Count=1/1 Maskable- 64bit+
Capabilities: [e0] Express Endpoint, MSI 00
Capabilities: [100] Advanced Error Reporting
Capabilities: [140] Device Serial Number bc-77-37-ff-ff-0d-3f-90
Kernel driver in use: pci-stub


Also, just to be clear, I was able to boot into this VM fine before adding the wireless card as a PCI passthrough device, and once I remove it via virt-manager, everything goes back to working as usual.



Does anyone have any idea how to fix this? Thanks!










share|improve this question















I am trying to set up PCI passthrough in virt-manager to grant my Debian Wheezy guest VM access to my laptop's Intel Centrino N wireless card.



The Debian default kernel has Intel IOMMU enabled, and I have passed intel_iommu=on to the kernel at boot (by editing /etc/default/grub and setting GRUB_CMDLINE_LINUX="intel_iommu=on", and then running grub-update) ...



Looking at dmesg to verify that IOMMU is indeed enabled, I see: [ 0.000000] Intel-IOMMU: enabled ...



I tried following the instructions here, and used virsh to detach the PCI device before adding it to the VM (i.e. virsh nodedev-detach pci_0000_01_00_0) just to be sure.



However, I cannot boot into the guest VM at all with PCI passthrough enabled for this wireless card, and I am getting the following error (from /var/log/libvirt/libvirtd.log):



2014-09-22 04:45:19.325+0000: 2990: error : qemuMonitorOpenUnix:305 : failed to connect to monitor socket: No such process
2014-09-22 04:45:19.325+0000: 2990: error : qemuProcessWaitForMonitor:1593 : internal error process exited while connecting to monitor: char device redirected to /dev/pts/1
**No IOMMU found. Unable to assign device "hostdev0"
kvm: -device pci-assign,host=01:00.0,id=hostdev0,configfd=22,bus=pci.0,addr=0x7: Device 'pci-assign' could not be initialized**


Here is the full output from /var/log/libvirt/qemu/:



2014-09-22 04:10:47.002+0000: starting up
LC_ALL=C PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin HOME=/ QEMU_AUDIO_DRV=none /usr/bin/kvm -S -M pc-1.1 -cpu Nehalem,+rdtscp,+avx,+osxsave,+xsave,+tsc-deadline,+x2apic,+pdcm,+xtpr,+tm2,+est,+vmx,+ds_cpl,+monitor,+dtes64,+pclmuldq,+pbe,+tm,+ht,+ss,+acpi,+ds,+vme -enable-kvm -m 2500 -smp 4,sockets=4,cores=1,threads=1 -name DebianStableSandbox -uuid c18e2808-c98a-2b4d-54f1-00977d3ec1d2 -no-user-config -nodefaults -chardev socket,id=charmonitor,path=/var/lib/libvirt/qemu/DebianStableSandbox.monitor,server,nowait -mon chardev=charmonitor,id=monitor,mode=control -rtc base=utc -no-shutdown -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 -drive file=/var/lib/libvirt/images/DebianNET.img,if=none,id=drive-virtio-disk0,format=raw -device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x5,drive=drive-virtio-disk0,id=virtio-disk0,bootindex=1 -drive if=none,id=drive-ide0-1-0,readonly=on,format=raw -device ide-cd,bus=ide.1,unit=0,drive=drive-ide0-1-0,id=ide0-1-0 -netdev tap,fd=21,id=hostnet0 -device virtio-net-pci,netdev=hostnet0,id=net0,mac=52:54:00:c5:4a:a9,bus=pci.0,addr=0x3 -chardev pty,id=charserial0 -device isa-serial,chardev=charserial0,id=serial0 -device usb-tablet,id=input0 -vnc 127.0.0.1:0 -vga cirrus -device intel-hda,id=sound0,bus=pci.0,addr=0x4 -device hda-duplex,id=sound0-codec0,bus=sound0.0,cad=0 -device pci-assign,host=01:00.0,id=hostdev0,configfd=22,bus=pci.0,addr=0x7 -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x6
char device redirected to /dev/pts/1
No IOMMU found. Unable to assign device "hostdev0"
kvm: -device pci-assign,host=01:00.0,id=hostdev0,configfd=22,bus=pci.0,addr=0x7: Device 'pci-assign' could not be initialized
2014-09-22 04:10:47.610+0000: shutting down


I think that the "failed to connect to monitor" message is somehow related. If I use virt-manager to add the wireless card as a PCI device, without first detaching it with virsh nodedev-detach (as mentioned above), then I get an error message from virt-manager saying:



Error starting domain: Unable to read from monitor: Connection reset by peer

Traceback (most recent call last):
File "/usr/share/virt-manager/virtManager/asyncjob.py", line 45, in cb_wrapper
callback(asyncjob, *args, **kwargs)
File "/usr/share/virt-manager/virtManager/asyncjob.py", line 66, in tmpcb
callback(*args, **kwargs)
File "/usr/share/virt-manager/virtManager/domain.py", line 1114, in startup
self._backend.create()
File "/usr/lib/python2.7/dist-packages/libvirt.py", line 620, in create
if ret == -1: raise libvirtError ('virDomainCreate() failed', dom=self)
libvirtError: Unable to read from monitor: Connection reset by peer


... and all that shows up in /var/log/libvirt/libvirtd.log in this case is: 2014-09-22 04:48:26.387+0000: 2985: error : qemuMonitorIORead:523 : Unable to read from monitor: Connection reset by peer



In case it is helpful, here is some of the relevant output from lspci -v:



00:00.0 Host bridge: Intel Corporation 2nd Generation Core Processor Family DRAM Controller (rev 09)
Subsystem: Dell Device 04d8
Flags: bus master, fast devsel, latency 0
Capabilities: [e0] Vendor Specific Information: Len=0c <?>
Kernel driver in use: agpgart-intel

00:1c.0 PCI bridge: Intel Corporation 6 Series/C200 Series Chipset Family PCI Express Root Port 1 (rev b5) (prog-if 00 [Normal decode])
Flags: bus master, fast devsel, latency 0
Bus: primary=00, secondary=01, subordinate=01, sec-latency=0
Memory behind bridge: d1600000-d16fffff
Capabilities: [40] Express Root Port (Slot+), MSI 00
Capabilities: [80] MSI: Enable- Count=1/1 Maskable- 64bit-
Capabilities: [90] Subsystem: Dell Device 04d8
Capabilities: [a0] Power Management version 2
Kernel driver in use: pcieport

01:00.0 Network controller: Intel Corporation Centrino Wireless-N 1030 [Rainbow Peak] (rev 34)
Subsystem: Intel Corporation Centrino Wireless-N 1030 BGN
Flags: fast devsel, IRQ 16
Memory at d1600000 (64-bit, non-prefetchable) [size=8K]
Capabilities: [c8] Power Management version 3
Capabilities: [d0] MSI: Enable- Count=1/1 Maskable- 64bit+
Capabilities: [e0] Express Endpoint, MSI 00
Capabilities: [100] Advanced Error Reporting
Capabilities: [140] Device Serial Number bc-77-37-ff-ff-0d-3f-90
Kernel driver in use: pci-stub


Also, just to be clear, I was able to boot into this VM fine before adding the wireless card as a PCI passthrough device, and once I remove it via virt-manager, everything goes back to working as usual.



Does anyone have any idea how to fix this? Thanks!







virtual-machine virtualization qemu pci virt-manager






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Sep 22 '14 at 5:14









Patrick

48.2k11126176




48.2k11126176










asked Sep 22 '14 at 5:08









J. Taylor

1,65211422




1,65211422




closed as off-topic by sebasth, schily, Jeff Schaller, msp9011, Thomas Sep 3 at 19:07


This question appears to be off-topic. The users who voted to close gave this specific reason:


  • "Questions describing a problem that can't be reproduced and seemingly went away on its own (or went away when a typo was fixed) are off-topic as they are unlikely to help future readers." – sebasth, schily, Jeff Schaller, msp9011, Thomas
If this question can be reworded to fit the rules in the help center, please edit the question.




closed as off-topic by sebasth, schily, Jeff Schaller, msp9011, Thomas Sep 3 at 19:07


This question appears to be off-topic. The users who voted to close gave this specific reason:


  • "Questions describing a problem that can't be reproduced and seemingly went away on its own (or went away when a typo was fixed) are off-topic as they are unlikely to help future readers." – sebasth, schily, Jeff Schaller, msp9011, Thomas
If this question can be reworded to fit the rules in the help center, please edit the question.







  • 1




    Are you sure your BIOS really supports IOMMU. The Xen wiki suggests that "there are many buggy BIOSes causing Xen to disable IO virtualization because of errors in the BIOS DMAR/ACPI tables."
    – StrongBad
    Sep 22 '14 at 9:08










  • I am using a Core-i5 2410M processor, and my BIOS is Phoenix SecureCore Tiano ... I can't find any info one way or the other whether this BIOS supports IOMMU or not.
    – J. Taylor
    Sep 24 '14 at 20:13











  • Actually, I just found out that this processor supports VT-x but not VT-d, so I can't do IOMMU.
    – J. Taylor
    Sep 25 '14 at 1:58










  • I want to know if the problem was solved by the author, as if the latest Linux version of the kernel suggested abolishing the KVM_ASSIGN mechanism and supporting only vfio
    – William Levi
    Sep 3 at 8:29










  • @WilliamLevi The problem was solved by the author; he even posted an answer about it. If you read his answer, you will see his solution. Though it may or may not apply to you because your situation is different.
    – Michael Hampton
    Sep 3 at 17:07












  • 1




    Are you sure your BIOS really supports IOMMU. The Xen wiki suggests that "there are many buggy BIOSes causing Xen to disable IO virtualization because of errors in the BIOS DMAR/ACPI tables."
    – StrongBad
    Sep 22 '14 at 9:08










  • I am using a Core-i5 2410M processor, and my BIOS is Phoenix SecureCore Tiano ... I can't find any info one way or the other whether this BIOS supports IOMMU or not.
    – J. Taylor
    Sep 24 '14 at 20:13











  • Actually, I just found out that this processor supports VT-x but not VT-d, so I can't do IOMMU.
    – J. Taylor
    Sep 25 '14 at 1:58










  • I want to know if the problem was solved by the author, as if the latest Linux version of the kernel suggested abolishing the KVM_ASSIGN mechanism and supporting only vfio
    – William Levi
    Sep 3 at 8:29










  • @WilliamLevi The problem was solved by the author; he even posted an answer about it. If you read his answer, you will see his solution. Though it may or may not apply to you because your situation is different.
    – Michael Hampton
    Sep 3 at 17:07







1




1




Are you sure your BIOS really supports IOMMU. The Xen wiki suggests that "there are many buggy BIOSes causing Xen to disable IO virtualization because of errors in the BIOS DMAR/ACPI tables."
– StrongBad
Sep 22 '14 at 9:08




Are you sure your BIOS really supports IOMMU. The Xen wiki suggests that "there are many buggy BIOSes causing Xen to disable IO virtualization because of errors in the BIOS DMAR/ACPI tables."
– StrongBad
Sep 22 '14 at 9:08












I am using a Core-i5 2410M processor, and my BIOS is Phoenix SecureCore Tiano ... I can't find any info one way or the other whether this BIOS supports IOMMU or not.
– J. Taylor
Sep 24 '14 at 20:13





I am using a Core-i5 2410M processor, and my BIOS is Phoenix SecureCore Tiano ... I can't find any info one way or the other whether this BIOS supports IOMMU or not.
– J. Taylor
Sep 24 '14 at 20:13













Actually, I just found out that this processor supports VT-x but not VT-d, so I can't do IOMMU.
– J. Taylor
Sep 25 '14 at 1:58




Actually, I just found out that this processor supports VT-x but not VT-d, so I can't do IOMMU.
– J. Taylor
Sep 25 '14 at 1:58












I want to know if the problem was solved by the author, as if the latest Linux version of the kernel suggested abolishing the KVM_ASSIGN mechanism and supporting only vfio
– William Levi
Sep 3 at 8:29




I want to know if the problem was solved by the author, as if the latest Linux version of the kernel suggested abolishing the KVM_ASSIGN mechanism and supporting only vfio
– William Levi
Sep 3 at 8:29












@WilliamLevi The problem was solved by the author; he even posted an answer about it. If you read his answer, you will see his solution. Though it may or may not apply to you because your situation is different.
– Michael Hampton
Sep 3 at 17:07




@WilliamLevi The problem was solved by the author; he even posted an answer about it. If you read his answer, you will see his solution. Though it may or may not apply to you because your situation is different.
– Michael Hampton
Sep 3 at 17:07










1 Answer
1






active

oldest

votes

















up vote
1
down vote



accepted










Actually, I just found out that this processor supports VT-x but not VT-d, so I can't do IOMMU.






share|improve this answer



























    1 Answer
    1






    active

    oldest

    votes








    1 Answer
    1






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes








    up vote
    1
    down vote



    accepted










    Actually, I just found out that this processor supports VT-x but not VT-d, so I can't do IOMMU.






    share|improve this answer
























      up vote
      1
      down vote



      accepted










      Actually, I just found out that this processor supports VT-x but not VT-d, so I can't do IOMMU.






      share|improve this answer






















        up vote
        1
        down vote



        accepted







        up vote
        1
        down vote



        accepted






        Actually, I just found out that this processor supports VT-x but not VT-d, so I can't do IOMMU.






        share|improve this answer












        Actually, I just found out that this processor supports VT-x but not VT-d, so I can't do IOMMU.







        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered Sep 25 '14 at 1:59









        J. Taylor

        1,65211422




        1,65211422












            Popular posts from this blog

            How to check contact read email or not when send email to Individual?

            Bahrain

            Postfix configuration issue with fips on centos 7; mailgun relay