Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 4 Apr 2001 18:12:46 -0700
From:      dannyman <dannyman@toldme.com>
To:        freebsd-hackers@freebsd.org
Subject:   creating an fdisk partition in an automated way
Message-ID:  <20010404181245.P40739@dell.dannyland.org>

next in thread | raw e-mail | index | archive | help
Ooookay ...

So, I gave up on sysinstall and wrote a script that beautifully runs disklabel
and newfs slices for me, writing an fstab and installing packages after
starting off a PXE boot.  It is just COOL!

Now all my test machines wont boot.  The hard disk boot just doesn't DO
anything, and the pxeboot crashes once it sees the SCSI disk.  Best I can
tell from some Deja searches, this is related to the Adaptec controller
reviling at the thought of a "dangeously dedicated" disk.

But I can not for the life of me figure out how to do it the right way.

Because it's cute, I attach my script.  I've tried changing disk to da0s1 and
it works JUST FINE on another IDE-based system on its spare SCSI disk, but
gets upset at me when I try to run the disklabel commands on my test machines.
I believe I need to do something with fdisk but I can not fathom quite what it
is from the man page.

The working disk looks like so:

0-17:55 root@cronic /usr/local/share/netboot# fdisk da0
******* Working on device /dev/da0 *******
parameters extracted from in-core disklabel are:
cylinders=1115 heads=255 sectors/track=63 (16065 blks/cyl)

Figures below won't work with BIOS for partitions not in cyl 1
parameters to be used for BIOS calculations are:
cylinders=1115 heads=255 sectors/track=63 (16065 blks/cyl)

Media sector size is 512
Warning: BIOS sector numbering starts with sector 1
Information from DOS bootblock is:
The data for partition 1 is:
sysid 165,(FreeBSD/NetBSD/386BSD)
    start 63, size 17912412 (8746 Meg), flag 80 (active)
        beg: cyl 0/ sector 1/ head 1;
        end: cyl 1023/ sector 63/ head 254
The data for partition 2 is:
<UNUSED>
The data for partition 3 is:
<UNUSED>
The data for partition 4 is:
<UNUSED>

The SCSI drives on my test machines, larger Seagates, start out similar, but
they have their goods in partition 4.  In their previous lives they were
Solaris x86 boxen, which is why I figure the sysid 165 stuff looks the same.
:)

Can someone please clue me in? :)

Thanks,
-danny

-- 
http://dannyman.toldme.com/

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20010404181245.P40739>