Solved Switch does not survive reboot and other network changes

In your last "host ifconfig", the bridge and ue0 have the same ip address. This cannot work. You have to choose if you put the bridge or ue0 under DHCP (or a fixed ip). It's better to set DHCP (or a fixed ip) on the bridge if you are on FreeBSD 15.

I don't know how vm-bhyve is functioning, but if you want the bridge to have DHCP at startup, you need to create it in rc.conf, addm ue0 and set SYNDHCP, like this:
Code:
cloned_interface="bridge0"
ifconfig_bridge0_name="vmpublic"
ifconfig_vmpublic="addm ue0 SYNDHCP"
I think you can't use "vm-public" as name in rc.conf because it contains a non-alphanumeric character.

Is it possible to do the same with vm-bhyve? I don't know.

You can do that with a script also ( service dhclient forcestart vmpublic).

Normally, it works also with an ip on ue0 (DHCP for instance) and no ip on the bridge. You just will get a warning if you are under FreeBSD 15.
 
For what I understood the "switch" must have the same IP of your NIC if you use the vm-switch, otherwise you can manage manually as you did, but I wouldn't trust very much what I understood… 😓
 
For what I understood the "switch" must have the same IP of your NIC if you use the vm-switch, otherwise you can manage manually as you did, but I wouldn't trust very much what I understood… 😓
You can't have the same ip on two interfaces, that's for sure. The network will work badly if not at all.

In addition, for the VM communicates with the host, its tap needs to be a member of the bridge (I imagine that vm-bhyve does this when the vm is launched).
 
Back
Top