On 31/01/2008, frantisek holop <[EMAIL PROTECTED]> wrote:
>
> nevertheless, the previous post very well pointed out that i will
> need to work with ffs from linux, and i dont know anything about that,
> not even if it is supported.

Like most BSDs, OpenBSD uses the Berkeley Fast File System. By
default, GNU/Linux^W^W^WLinux (yes, Linux, motherfucker, Linux!)
allows you to mount Fast File System partitions, but (at least on
Ubuntu 7.10) it can by default only mount them read-only.

For instance to mount an OpenBSD floppy on an Ubuntu 7.10 box, try this:

sudo mkdir /media/floppy
sudo mount -t ufs -o ufstype=44bsd -r /dev/fd0 /media/floppy

Obviously,
sudo umount /media/floppy
when finished, and adapt the above as necessary if you're dealing with
HDDs/USB sticks.

Now you would have been able to figure this out by yourself with man
mount -- but that requires the prior knowledge that (Berkeley) Fast
File System = FFS = UFS = Unix File System to clue in to selecting the
ufs type, and you then have to know that you need to also set the
ufstype option to 44bsd. Thankfully, dmesg|tail is helpful if you
don't set the ufstype option:

[15809.331413] You didn't specify the type of your ufs filesystem
[15809.331417]
[15809.331418] mount -t ufs -o
ufstype=sun|sunx86|44bsd|ufs2|5xbsd|old|hp|nextstep|nextstep-cd|openstep
...
[15809.331421]
[15809.331421] >>>WARNING<<< Wrong ufstype may corrupt your
filesystem, default is ufstype=old

man mount has this to say about the ufstype option:
> Mount options for ufs
>        ufstype=value
>               UFS is a file system widely used in different operating 
> systems. The
>               problem are[sic] differences among  implementations.  Features  
> of
>               some  implementations  are undocumented, so its hard to 
> recognize
>               the type of ufs automatically.  That's why the user must 
> specify the type
>               of ufs by mount option.  Possible values are:
>
>              old    Old  format of ufs, this is the default, read only.  
> (Don't forget to
>                      give the -r option.)
>
>              44bsd  For filesystems created by a BSD-like system
>                      (NetBSD,FreeBSD,OpenBSD).

If I read the above correctly, then it should even be possible to
mount the ufs type with the ufstype=44bsd option as read+write, but
when I tried this on Ubuntu 7.10, I got this:

[EMAIL PROTECTED]:~/Desktop$ sudo mount -t ufs -o ufstype=44bsd
/dev/fd0 /media/floppy
mount: wrong fs type, bad option, bad superblock on /dev/fd0,
       missing codepage or helper program, or other error
       In some cases useful info is found in syslog - try
       dmesg | tail  or so

[EMAIL PROTECTED]:~/Desktop$ dmesg|tail
(...)
[16157.855996] ufs was compiled with read-only support, can't be
mounted as read-write
[EMAIL PROTECTED]:~/Desktop$

So maybe it's possible to compile in r+w support into your Linux
kernel, or maybe your favourite distro already comes with write
support for 44bsd FFS compiled in. YMMV.

(I'm sorta considering filing an Ubuntu launchpad bug for this, to ask
the maintainers if they can compile in r+w support for OpenBSD (and
the others) in the next release. Don't count on me though. I'm way
over my head in all sorts of stuff.)

Hopefully this info helps you in your migration from Linux to OpenBSD. ;-P ;-)
Good luck! :)

best regards,
--ropers

Reply via email to