Xen 未检测到 xenbr0

Xen 未检测到 xenbr0

我正在尝试创建一个 HVM,但是当我启动它时,我发现它失败并在命令行上显示以下错误消息:

[root@xs5 xen]# xl create devoracle.cfg
Parsing config from devoracle.cfg
libxl: error: libxl_exec.c:118:libxl_report_child_exitstatus: /etc/xen/scripts/vif-route online [24897] exited with error status 1
libxl: error: libxl_device.c:1219:device_hotplug_child_death_cb: script: /etc/xen/scripts/vif-route failed; error detected.
libxl: error: libxl_create.c:1462:domcreate_attach_vtpms: unable to add nic devices
libxl: error: libxl_exec.c:118:libxl_report_child_exitstatus: /etc/xen/scripts/vif-route offline [25012] exited with error status 1
libxl: error: libxl_device.c:1219:device_hotplug_child_death_cb: script: /etc/xen/scripts/vif-route failed; error detected.
libxl: error: libxl_exec.c:118:libxl_report_child_exitstatus: /etc/xen/scripts/block remove [24999] exited with error status 1
libxl: error: libxl_device.c:1219:device_hotplug_child_death_cb: script: /etc/xen/scripts/block failed; error detected.
libxl: error: libxl_exec.c:118:libxl_report_child_exitstatus: /etc/xen/scripts/block remove [25002] exited with error status 1
libxl: error: libxl_device.c:1219:device_hotplug_child_death_cb: script: /etc/xen/scripts/block failed; error detected.
libxl: error: libxl_exec.c:118:libxl_report_child_exitstatus: /etc/xen/scripts/vif-route remove [25132] exited with error status 1
libxl: error: libxl_device.c:1219:device_hotplug_child_death_cb: script: /etc/xen/scripts/vif-route failed; error detected.
libxl: error: libxl.c:1583:libxl__destroy_domid: non-existant domain 40
libxl: error: libxl.c:1542:domain_destroy_callback: unable to destroy guest with domid 40
libxl: error: libxl.c:1471:domain_destroy_cb: destruction of domain 40 failed
[root@xs5 xen]# 

我的配置当前针对 VIFS 进行设置:

vif = [ "script=vif-route" ]

我尝试了不同的组合,例如添加 xenbr0(以及 xenbr1)的 mac 地址和设备名称,但始终无法找到。Xenbr0 确实存在,我可以在 ifconfig 中看到它:

xenbr0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 192.168.x.x  netmask 255.255.255.0  broadcast 192.168.x.x
        ether blah  txqueuelen 1  (Ethernet)
        RX packets 55823814  bytes 318634247570 (296.7 GiB)
        RX errors 0  dropped 677426  overruns 0  frame 0
        TX packets 48675218  bytes 63768868848 (59.3 GiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

xenbr1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        ether foo  txqueuelen 1  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

此外,当我运行该命令时,我看到 xen-hotplug.log 中发生了以下情况:

xenstore-read: couldn't read path backend/vbd/40/768/node
xenstore-read: couldn't read path backend/vbd/40/832/node

我在运行创建命令时生成的日志文件中看到了这一点:

qemu: ignoring not-understood drive `be:0x4f96ba:40:0x733540'
medium change watch on `be:0x4f96ba:40:0x733540' - unknown device, ignored

我是否遗漏了什么?任何建议或帮助都将不胜感激。

更新:从配置中注释掉 vifs 行允许 HVM 启动,但如果是这种情况,这将不允许与外界连接。任何关于这方面的建议都会对我有帮助。

答案1

我遇到了同样的问题Debian 9 StretchXen 4.9

问题在于/etc/xen/scripts/vif-route:第 26 行下ifconfig使用了。出于某种原因,Debian 将其替换ifconfigip address,因此您需要安装net-tools才能使 vif-route 脚本正常工作:

apt install net-tool 

相关内容