Can't Remove CDROM from Bhyve VM

jlw52761

Explorer
Joined
Jan 6, 2020
Messages
87
So I'm really puzzled on this one. When I install Ubuntu 16.04 on the VM, things are fine, reboots are just fine, until I remove the CD device (since you can't have a CD without an ISO). When I do this, well, I get dumped into an EFI shell and even adding the device back requires a rescue or rebuild.

So what gives with this? I have a very long and heavy background in ESXi and KVM, so virtualization is not new to me, just this Bhyve hypervisor and never have had to have a ISO image be a permanent fixture of a VM.
 

sretalla

Powered by Neutrality
Moderator
Joined
Jan 1, 2016
Messages
9,703

jlw52761

Explorer
Joined
Jan 6, 2020
Messages
87
Was going to update this when I saw your post and I have an interesting development. What I did was get the OS installed again and this time instead of powering off the VM then removing the CDROM, I removed the CDROM while the VM was powered on. Interesting enough, it boots just find and the /boot/efi/EFI directory looks correct. But now, I have no network stack, which I confirmed worked when the CDROM was attached, so I'm guessing something get's screwed up in the PCI device list when the CDROM is removed, not sure.
 

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,776
Yep. The ethernet device changes its name. Check with ifconfig -a and adjust /etc/netplan/something accordingly. Or ist it still /etc/network/interfaces? You'll manage ;)

Patrick
 

jlw52761

Explorer
Joined
Jan 6, 2020
Messages
87
So the interface was the same, enp0s4 both before and after the CDROM, which is what prompted me to come and see if there's something else. I can't accurately reproduce the issue, it seems very random but I'm starting to wonder if it's having to do with my 802.1q trunk going to the box and my expectation that I can use it like I would in something like ESXi or Ubuntu by creating a new VLAN interface with the right tag and attach the jail or VM to that. It doesn't seem to be the case and when when I do add the VLAN interface I get some odd behavior where the WUI tends to disconnect for a few seconds every minute or so. Removing the interface and the WUI stays stable. So I'm going to run this down and then circle back to see if my issue with the weird disconnects in the VM or jail are the same.

Basically, just for background, I have a trunk going to my FreeNAS that has the native VLAN defined as 30, which is my static "server" VLAN. I then have my DHCP VLAN, 34, allowed in the trunk, so under ESXi I would just create a portgroup that tags the traffic and attach my VMs there. I assumed that FreeNAS was the same but apparently not. I have two ESXi systems on the same switch with the same trunk config and things work as expected, so it's something either goofy with FreeNAS/FreeBSD or my lack of experience with FreeBSD showing. I'm a Linux guy by trade and before that a SCO geek.
 

danwize

Cadet
Joined
Sep 21, 2021
Messages
1
I got it to work by powering off my VM and going to it's settings. Under devices I found my cd rom and deleted the device. Now my Ubuntu install boots up just fine.
 
Top