Commit a6c637b
committed
fix(drivers): boot port must always use network-type interface
LibvirtPoolDriver.create_machine() applied the hypervisor's own
network_type (bridge/network) to every port it's given, including the
initial boot-network port. The boot network is always a plain libvirt
virtual network regardless of the hypervisor's main network type, so
on a bridge-type hypervisor libvirt tried to treat the boot network's
name as a literal host bridge device name and rejected it as too long
for IFNAMSIZ.
Only force type='network' for the boot-network port specifically
(identified via the new BOOT_NETWORK_PORT_UUID sentinel, see
Port.from_boot_network()). Any other port - including the real port(s)
create_machine() is given when recreate_machine() rebuilds the domain
post-flash - keeps honoring network_type, since real bridge-type
hypervisors do use raw bridge-type interfaces (source=<bridge device>),
not a libvirt network wrapping one.
attach_port(), used only for the real port, is unaffected.1 parent 615d27a commit a6c637b
3 files changed
Lines changed: 20 additions & 15 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
29 | 34 | | |
30 | 35 | | |
31 | 36 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
769 | 769 | | |
770 | 770 | | |
771 | 771 | | |
772 | | - | |
773 | | - | |
774 | | - | |
| 772 | + | |
| 773 | + | |
| 774 | + | |
775 | 775 | | |
776 | 776 | | |
777 | 777 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1198 | 1198 | | |
1199 | 1199 | | |
1200 | 1200 | | |
1201 | | - | |
1202 | | - | |
1203 | | - | |
1204 | | - | |
1205 | | - | |
1206 | 1201 | | |
1207 | | - | |
| 1202 | + | |
1208 | 1203 | | |
1209 | 1204 | | |
1210 | 1205 | | |
| |||
1303 | 1298 | | |
1304 | 1299 | | |
1305 | 1300 | | |
1306 | | - | |
1307 | | - | |
1308 | | - | |
1309 | | - | |
1310 | | - | |
1311 | | - | |
| 1301 | + | |
| 1302 | + | |
| 1303 | + | |
| 1304 | + | |
| 1305 | + | |
| 1306 | + | |
| 1307 | + | |
| 1308 | + | |
| 1309 | + | |
| 1310 | + | |
| 1311 | + | |
1312 | 1312 | | |
1313 | 1313 | | |
1314 | 1314 | | |
| |||
0 commit comments