- Thread Starter
- #26
Doesn't have that specific file, although I did previously extract the 11.1 (or perhaps 11.2) kernel.txz from ftp.freebsd.org. No change.Does that rescue media have a kernel.txz? Just extract that to overwrite the botched kernel. It's probably going to be a 11.2 kernel but that's less likely to cause problems on a 11.1 userland than a 12.2 kernel might.
Instead, I copied the contents of /boot from the rescue image (including the empty loader.conf) to the zroot file system, then wrote out the boot code from the rescue image.
To mount pool and change to its / as cwd
zpool import -R /tmp/mnt 13406323999712830393
umount /tmp/mnt
mount -t zfs zroot/ROOT/default /tmp/mnt
cd /tmp/mnt
Then:
mv ./boot ./oldboot
mkdir boot
rsync -av /boot/ ./boot/
# copies from /boot/ to /tmp/mnt/boot/ gpart bootcode -b /boot/pmbr -p /boot/gptzfsboot -i 1 ada0
shutdown -r now
Now, unless something is seriously wrong, surely copying the kernel and bootcode of a known working setup would be sufficient to boot far enough that it logs something, but for some reason, it does not seem to get to the point of mounting zroot. I have checked /var/log/messages (when booted under rescue) to see if there are any warnings about hardware, corrupt partitions, and so on - nothing.
Am I doing something wrong with the way I mount it under rescue? Here's
zfs mount
Code:
NAME USED AVAIL REFER MOUNTPOINT
zroot 1.24T 528G 96K /tmp/mnt/zroot
zroot/ROOT 1.24T 528G 96K none
zroot/ROOT/default 1.24T 528G 1.24T /tmp/mnt
I do not export the pool before reboot. Should I be doing this? Could it be that it's refusing to auto-mount because it was last accessed by a 'different' system (rescue)?
I've just ordered a new server, so I will try exporting before reboot purely out of curiosity. [edit: Behaviour did not change.]