Upgrade from 12.x to 13.0 - ESXI 6.5 no /boot/loader

This has happen to me twice now, under different circumstances. It seems there's an issue with Esxi 6.5 and the boot loader. The first time was with a VM that's been up for 2+ years, hot migrated from 6.0 to 6.5. Had to reboot it and it came up unable to find the boot partition. This time it's with another VM that was running FreeBSD 12.2 and upgrading to 13.0. I had previously upgraded it the same day from 12.0->12.1->12.2 without any issues. Now with 13.0 it doesn't boot. I can go into liveCD and the partitions are there, but the boot loader has an issue with what its initially set to with what ESXI 6.5 has assigned the devices is my guess? When I try "mount /dev/da0s1a /mnt" from liveCD I get "file not found". Anyone know what the issue is and what I need to do to the loader to get the right device back?



boot2.png


From liveCD:

boot1.png


The boot partition is the 10G one on da0s1a (1).
 
Yep, tried mounting it, that gave errors of "file not found". I really wish I knew what happened. Whatever happed the drive was not clean and it had 4 sectors that wouldn't repair. But this is on a vSAN and there's nothing wrong on it. I even cloned the system to another VM and it showed the same 4 sectors on the cloned VM as bad, so something was whacky with the disk structure.

I ended up restoring from a backup and now reapplying updates again doing snapshots before each update. Also changed the VM to Unix Other (64 bit), since ESXI 6.5 doesn't list FreeBSD 12 or 13 (The matrix shows them in ESXI 6.7 and 7.x). I'll update the thread once I get back to 12.2 and then if the jump to 13.0 repeats.
 
So confirmed and repeatable. Restored from a backup(see previous post) that was working before upgrades. I was able to upgrade from 12.0 to 12.1 to 12.2 fine. When I made the next jump to 13.0 I was again left when a non-bootable system. Same screenshot as in the first post. I'll try and see if LiveCD will let me mount it. Worse case, I cloned the VM this time before starting any updates (along with snapshots), so I can spin up the clone if I have to.
 
Nope, again unable to mount the drive to get to the file system and modify the loader. Any ideas what to try next?

kn1.png
 
It almost seems like your partition gets overwritten during upgrade. Could you do a dd if=/dev/da0 skip=63 bs=512 count=1 > before_ad0 and do the same after the upgrade ? Share the files here then.
Personally I'd avoid using the MBR mess but that's just a side note to the problem.
 
Yeah, the MBR is really from this box starting out as FreeBSD 9.0 (maybe earlier) ages ago and getting upgraded over the years. In retrospect, it'd probably of been easier to rebuild from scratch a 13.0 system. Which is what I've done, using ZFS, but now the disks still won't mount to copy the data over. I have the 12.2 version backup running for now while I fiddle with the 13.0, I could copy what I need from the run 12.2 over to the new 13.0 box, but I don't mind spending time on the broken vm, because i have about 10 other boxes that are on various versions of 10.x-12.x that would be much simpler using the FreeBSD-Upgrade options rather then all new installs... Though from what I'm reading, and my FreeNAS box uses ZFS, it might be useful to do that anyways and get off the MBR/UFS setup, which is a PITA to modify as GPart CD ISO doesn't allow any modifications to a ufs partition.

file -s /dev/da0s1a ?
fsck_ffs -b192 /dev/da0s1a ?
Yeah, it's there. The device changed from previous post as I put a ZFS partition in front of this and built a new 13.0 system. But now this is preventing me from mounting and getting the data moved over. I have a 12.2 clone running that I can use, but it'd be nice to know wth happened!

Screenshot 2021-11-30 161052.png
 
It almost seems like your partition gets overwritten during upgrade. Could you do a dd if=/dev/da0 skip=63 bs=512 count=1 > before_ad0 and do the same after the upgrade ? Share the files here then.
Personally I'd avoid using the MBR mess but that's just a side note to the problem.
Yeah, I'll have to avoid doing that for now, not really going to put a disk with employer info and firewall setup here for all to grab...
 
Yeah, I'll have to avoid doing that for now, not really going to put a disk with employer info and firewall setup here for all to grab...
Yep
It almost seems like your partition gets overwritten during upgrade. Could you do a dd if=/dev/da0 skip=63 bs=512 count=1 > before_ad0 and do the same after the upgrade ? Share the files here then.
Personally I'd avoid using the MBR mess but that's just a side note to the problem.
I believe you are correct. I loaded up a live gpart CD, those partitions used to show as UFS, now they are unknown. FreeBSD gpart shows the correct geomertry, but the superblock is gone. Oh well, I'll use the 12.2 running system for now while I rebuild a new 13.0. Thanks for the help.
 
Back
Top