Created attachment 353802 [details] Qemu-kvm log file Description of problem: If I attempt to assign a PCI network card directly to a virtual machine (using virt-manager => Details => Add Hardware => Physical Host Device {PCI Device, 00:09:0 MCP55 Ethernet}, when I then boot the vm: (a) I get selinux avcs; might be bug #499259, but that's supposed to be closed, fixed in selinux-policy-3.6.12-29, but I have selinux-policy-3.6.12-62.fc11.noarch and virt_manage_sysfs --> on (should I report this on that bug or elsewhere?) (b) If I do setenforce permissive and try again, virt-manager flickers briefly and the virtual console goes back to saying "Guest not running" (reckon this is a bug in virt-manager: it should say something helpful -- shall I raise a separate bug for that too?). Looking at /var/log/libvirt/qemu/$vm.log, I see: create_userspace_phys_mem: Invalid argument assigned_dev_iomem_map: Error: create new mapping failed Version-Release number of selected component (if applicable): qemu-0.10.5-3.fc11.x86_64 How reproducible: Completely Steps to Reproduce: 1. copy minimal kickstart $ cp /usr/share/doc/livecd-tools-024/livecd-fedora-minimal.ks . 2. edit that so that it refers to fedora 11: repo --name=released --mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=fedora-11&arch=$basearch (at time of writing adding the updates repo makes no difference) 3. sudo livecd-creator --config livecd-fedora-minimal.ks --cache somewhere-handy -f livecd-fedora-minimal 2. use virt-manager to create a virtual machine from that livecd (can disable storage for this virtual machine) 3. use virt-manager to assign a physical ethernet device to that vm (using virt-manager => Details => Add Hardware => Physical Host Device {PCI Device, 00:09:0 MCP55 Ethernet} in my case [ 4a. Click on run, get selinux denials SELinux is preventing qemu-kvm (svirt_t) "sys_rawio" svirt_t. SELinux is preventing qemu-kvm (svirt_t) "sys_admin" svirt_t. ] 4b. setenforce permissive, click on run again. Actual results: A message is displayed in the vm console window too briefly to be read and reverts to "Guest not running", errors in the vm's log Expected results: A running vm with a real PCI network device Additional info: Not sure if this is specific to x86_64.
The best thing to do might be to try this from the command line using virsh; once we've got device assignment working there, we can figure out what other bugs are worth filing First of all, do you have a machine with VT-d support enabled? i.e. if you boot with intel_iommu=on, what does 'dmesg | grep DMAR' show ? There's a bunch more info here which might be useful: http://fedoraproject.org/wiki/Test_Day:2009-05-07_Virtualization_KVM_PCI_Device_Assignment
>First of all, do you have a machine with VT-d support enabled? I'm not familiar with the terminology > i.e. if you boot with intel_iommu=on, what does 'dmesg | grep DMAR' show ? Nothing, but then it is an AMD box. I'll attach /proc/cpuinfo
Created attachment 356996 [details] /proc/cpuinfo
(In reply to comment #2) > >First of all, do you have a machine with VT-d support enabled? > > I'm not familiar with the terminology > > > i.e. if you boot with intel_iommu=on, what does 'dmesg | grep DMAR' show ? > > Nothing, but then it is an AMD box. I'll attach /proc/cpuinfo Okay, PCI device assignment on AMD machines requires the machine to have IOMMU support. AFAIK, only very recent AMD Shanghai or Istanbul based platforms have this. The Athlon 64 X2 doesn't have it The error message is terrible, though, I'll grant you that :-) Thanks for the report