OpenBSD -> FreeBSD migration

Andrew Hamilton-Wright andrewhw at ieee.org
Wed Apr 23 20:01:17 UTC 2008


The results of my investigation so far are below:

> Filesystem stuff:
>  - it appears that FreeBSD and OpenBSD use the same partition
>    table format.  Is this true?  If so, I can potentially avoid
>    rebuilding an entire disk if I am right that ...
>  - FreeBSD can mount and read OpenBSD's version of the 4.2 BSD
>    filesystem implementation

Although I strongly suspect that the filesystem itself is probably
the same, it is not possible to read an OpenBSD mounted partition,
as far as I can tell.

After booting using FreeBSD, fdisk correctly reports the information
regarding the slice set up by OpenBSD (default 4, not 1, the FreeBSD
default), however bsdlabel under FreeBSD cannot interpret any of the
data found at the location reported in the table read by fdisk.  I
do find this somewhat surprising, as it is the same structures that
are being recorded.  Perhaps there is a magic number issue here
that causes bsdlabel to believe that it can't interpret the data
as the message returned is that there is no label present in the
indicated slice.

This makes the filesystem question moot, as without access to
the BSD partition results there is no clue as to where to begin
access of the filesystem.


>  - even if the above isn't true, it appears that the format used
>    by dump/restore is consistent.  I have tried dumping/restoring
>    some small filesystems to test this, but if this is an unsupported
>    way to go, I would like to know now.

This seems to work.  I was successfully able to dump filesystems
under OpenBSD and then restore them under FreeBSD, with general
success (albeit a complaint that the dump header is out of date).


Cheers,
Andrew.



More information about the freebsd-questions mailing list