Subject: Re: mounting 100% MS-DOS disk
To: Jan Morales <jan@homer.filetek.com>
From: Ken Hornstein <kenh@entropic.com>
List: netbsd-help
Date: 09/21/1994 20:12:32
>I have an IDE disk with MS-DOS and a SCSI disk with NetBSD 1.0_BETA.
>If you just turn the machine on it'll boot MS-DOS.  I have a floppy
>with a slightly-modified boot program (it defaults to hd(1,a)/netbsd)
>which I put in the floppy drive if I want to boot NetBSD.
>
>My question: there is no NetBSD partition on the IDE drive so how do
>I mount it on NetBSD as a msdosfs filesystem?

Here's a note I saved a while back from Charles Hannum that explains how to
get this to work without having to repartition.  I haven't tried this myself,
but it makes sense to me.

(Personally I'd think it would be nice if the disk driver would punt and give
you a "d" partition of the whole disk if it didn't find a Unix partition, but
since that's not my case here it hasn't bothered me much).

--Ken

Date:    Fri, 04 Mar 1994 07:50:08 PST
To:      current-users@sun-lamp.cs.berkeley.edu

From:    Charles Hannum <mycroft@sun-lamp.cs.berkeley.edu>
Subject: Mounting an all-DOS disk in NetBSD

Assuming you don't have something (like OS-BS) which uses the extra
sectors in the boot track, you can do the following:

1) Use the NetBSD `fdisk' or DOS `pfdisk' to create a NetBSD partition
in the MBR which spans the entire disk.

2) Save a copy of the MBR:

        dd if=/dev/rsd0d of=my-mbr bs=1b count=1

3) Use `disklabel' to create a NetBSD label with the DOS partition and
whatnot.  Answer `y' when it asks you if you want to `overwrite [a]
disk with [a] DOS partition table'.

4) Put back the saved copy of the MBR:

        dd if=my-mbr of=/dev/rsd0d bs=1b count=1

This works for me.  Your milage may vary.