- Thread Starter
- #101
randomcop said:Thanks yor your great Howto and the beadm script!
I have already done some testinstalls both under virtualbox and on some real server hardware and the zfs-on-root + beadm setup really works ok.
What really makes me nervous are thinkable situations, when I have an active boot environment that locks up right after the kernel is loaded or some other form of broken freebsd. How can I go back to a previous, stable boot environment, without being able to use the beadm script?
You will have to use FreeBSD LiveCD or LiveUSB and do it 'by hand'.
randomcop said:As an experiment I created a new boot environment from default, named "be1". I activated "be1" with beadm and on startup escaped to loader prompt. There I did:
- unload kernel
- set vfs.root.mountfrom=zfs:sys/ROOT/default (from vfs.root.mountfrom=zfs:sys/ROOT/be1)
- set currdev=zfs:sys/ROOT/default: (from currdev=zfs:sys/ROOT/be1
- load kernel
- load zfs
- boot
This leads to the the result, that - after the kernel loaded ok - sys/ROOT/default cannot be mounted and the following text is displayed:
mounting from zfs:sys/ROOT/default: failed with error 2
This error comes mostly when zpool.cache is not up to date, to make it up to date it requires to export and import a pool.
randomcop said:What can I do if I have a an active, but broken, boot environment, and want to revert to a previous, stable boot environment?
You will have to use FreeBSD LiveCD or LiveUSB and do it 'by hand' and with the zpool.cache 'regeneration' step.