Linux
Xen 可以配置為僅將雙埠 NIC 的一個埠專用於 domU 嗎?
我在我的 dom0 上使用帶有 Xen 核心的 CentOS 5.4。我正在嘗試使用 pciback 模組對主機隱藏一些乙太網埠,並將它們保留給我打算用於防火牆的 domU(過程在此處和此處描述)。但是,當我啟動 domU 時,我收到以下錯誤消息:
Using config file "/etc/xen/firewall". Error: pci: improper device assignment specified: pci: 0000:01:04.0 must be co-assigned to the same guest with 0000:01:06.0, but it is not owned by pciback.
lspci 給我以下輸出:
00:00.0 Host bridge: Intel Corporation 82945G/GZ/P/PL Memory Controller Hub (rev 02) 00:02.0 VGA compatible controller: Intel Corporation 82945G/GZ Integrated Graphics Controller (rev 02) 00:1d.0 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI Controller #1 (rev 01) 00:1d.1 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI Controller #2 (rev 01) 00:1d.2 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI Controller #3 (rev 01) 00:1d.3 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI Controller #4 (rev 01) 00:1d.7 USB Controller: Intel Corporation 82801G (ICH7 Family) USB2 EHCI Controller (rev 01) 00:1e.0 PCI bridge: Intel Corporation 82801 PCI Bridge (rev e1) 00:1f.0 ISA bridge: Intel Corporation 82801GB/GR (ICH7 Family) LPC Interface Bridge (rev 01) 00:1f.2 IDE interface: Intel Corporation 82801GB/GR/GH (ICH7 Family) SATA IDE Controller (rev 01) 00:1f.3 SMBus: Intel Corporation 82801G (ICH7 Family) SMBus Controller (rev 01) 01:04.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL-8139/8139C/8139C+ (rev 10) 01:06.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL-8139/8139C/8139C+ (rev 10) 01:07.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL-8139/8139C/8139C+ (rev 10)
從錯誤消息的聲音來看,似乎我還需要將 eth0(PCI ID 01:04.0)專用於 domU。我對麼?如果沒有,我做錯了什麼?謝謝!
正確 - 多功能設備(按規格)必須分配給同一域。
但是,在某些情況下,它仍然可以工作。您可能會很幸運 - 看起來您在同一張卡上有多個設備,而不是單個多功能設備。
嘗試設置
pci-passthrough-strict-check no
,/etc/xen/xend-config.sxp
它可能會起作用。