Can't boot from another slice (long)

Francis Gudin fgudin at nerim.net
Tue Nov 15 02:18:14 PST 2005


Hello,

I'm trying to follow the steps described in article "FreeBSD From
Scratch". All went ok until rebooting: it just hangs.
The details:

My fdisk output:
> sudo fdisk ad0
******* Working on device /dev/ad0 *******
parameters extracted from in-core disklabel are:
cylinders=4864 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=4864 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 7,(OS/2 HPFS, NTFS, QNX-2 (16 bit) or Advanced UNIX)
    start 63, size 3984057 (1945 Meg), flag 0
        beg: cyl 0/ head 1/ sector 1;
        end: cyl 247/ head 254/ sector 63
The data for partition 2 is:
sysid 165,(DragonFly/FreeBSD/NetBSD/386BSD)
    start 3984120, size 3984120 (1945 Meg), flag 80 (active)
        beg: cyl 248/ head 0/ sector 1;
        end: cyl 495/ head 254/ sector 63
The data for partition 3 is:
sysid 165,(DragonFly/FreeBSD/NetBSD/386BSD)
    start 7968240, size 3984120 (1945 Meg), flag 0
        beg: cyl 496/ head 0/ sector 1;
        end: cyl 743/ head 254/ sector 63
The data for partition 4 is:
sysid 165,(DragonFly/FreeBSD/NetBSD/386BSD)
    start 11952360, size 66187800 (32318 Meg), flag 0
        beg: cyl 744/ head 0/ sector 1;
        end: cyl 1023/ head 254/ sector 63

Slice n°3 is the next-system wanabee: i installed a 1_2_Slip'ed from
yesterday onto it and from the active slice, everything seems well:

> sudo disklabel ad0s3
# /dev/ad0s3c:
type: unknown
disk: amnesiac
label:
flags:
bytes/sector: 512
sectors/track: 63
tracks/cylinder: 255
sectors/cylinder: 16065
cylinders: 248
sectors/unit: 3984120
rpm: 3600
interleave: 1
trackskew: 0
cylinderskew: 0
headswitch: 0           # milliseconds
track-to-track seek: 0  # milliseconds
drivedata: 0

16 partitions:
#        size   offset    fstype   [fsize bsize bps/cpg]
  a:   512000        0    4.2BSD     1024  8192    22   # (Cyl.    0 - 31*)
  b:   512000   512000    4.2BSD     2048 16384    94   # (Cyl.   31*- 63*)
  c:  3984120        0    unused        0     0         # (Cyl.    0 - 247)
  d:  2960120  1024000    4.2BSD     1024  8192    22   # (Cyl.   63*- 247*)

In fact, except for the comment line, it's ad0s2' twin :-)
Also, all needed files are there to my understanding:
> mount
/dev/ad0s2a on / (ufs, local)
/dev/ad0s2b on /var (ufs, local)
/dev/ad0s2d on /usr (ufs, local, soft-updates)
/dev/ad0s4b on /tmp (ufs, local)
/dev/ad0s4d on /usr/home (ufs, local)
procfs on /proc (procfs, local)
/dev/ad0s3a on /newroot (ufs, local, soft-updates)
/dev/ad0s3b on /newroot/var (ufs, local, soft-updates)
/dev/ad0s3d on /newroot/usr (ufs, local, soft-updates)
> ls /newroot/
COPYRIGHT       dev             modules         slice_3         usr
bin             etc             proc            src             var
boot            kernel          root            sys
compat          mnt             sbin            tmp
> ls /newroot/boot/
beastie.4th     boot2           loader          mbr
boot            cdboot          loader.4th      pxeboot
boot0           defaults        loader.help     screen.4th
boot1           frames.4th      loader.rc       support.4th

Now, the behaviour: at the "boot0" slice selection menu, pressing F3
just hangs (well i'm still able to 3-fingers salute it). I played a bit
with boot0 but can't quite understand the naming scheme and what's
expected from there...
Maybe more informational is the attempt to boot on F2, as usual, and
break at the loader prompt: after "set currdev=disk1s3a:", "ls" itself
hangs :-/ I wonder my slice is properly prepared ?
I'm thinking also about trying to put a more recent boot0 in place, but
as i feel it a bit adventurous rewriting my MBR, i"d like to ask you
about it:
would "sudo /newroot/usr/sbin/boot0cfg -B -b /newroot/boot/boot0" help
and run correctly ?

Thanks in advance for any hints,

Francis.





More information about the Users mailing list