Dual-boot with common ZFS

Allan Jude allanjude at freebsd.org
Sat Dec 27 17:54:17 UTC 2014


On 2014-12-27 11:44, Eric McCorkle wrote:
> It looks like I'm going to have to install Linux on my laptop for a while because of lack of driver support (haswell graphics).  However, I thought of an idea and wanted to see if anyone has done something similar.
> 
> I have a pure-ZFS setup, with a GPT.  I was wondering if it might be possible to use the same ZFS volume to hold both a Linux and a FreeBSD installation.  At least on the surface, it seems like you ought to be able to create separate file systems for each OS.  The real trick, I think, would be in finding the right boot/loader.conf arguments to point the kernels at the correct root, and the the right flags for ZFS mount to mount the other file systems correctly.
> 
> I can think of several things you could do with this scheme, among them being Linux-to-FreeBSD driver porting.  There's probably things you could do with virtualization layers as well.
> 
> Has anyone attempted such a setup, and if so, what were your experiences?
> _______________________________________________
> freebsd-hackers at freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe at freebsd.org"
> 

I have not attempted such a setup, but if I was going to, I'd probably
use the GRUB boot loader, like PCBSD does.

Then you can use their ZFS drivers, and specify the location of the
kernel (on different ZFS datasets), and what dataset to mount as root etc.

Basically, ZFS boot environments, where you have 1 that is FreeBSD and 1
that is Linux.

Your biggest issue with doing this with an existing ZFS install, is that
you may have used ZFS features that are too new for Linux to support
them. You might have to start over with a pool created with some of the
feature flags turned off (or create the pool under Linux, and don't
upgrade it on FreeBSD).

-- 
Allan Jude

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 834 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freebsd.org/pipermail/freebsd-hackers/attachments/20141227/71824b66/attachment.sig>


More information about the freebsd-hackers mailing list