Current-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: disklabel trouble



On Sat, Jul 16, 2011 at 05:55:34PM +0100, David Laight wrote:
> On Sat, Jul 16, 2011 at 04:31:16PM +0100, Patrick Welche wrote:
> > 
> > I must be missing something...
> 
> Have a look at what fdisk says.

# fdisk wd0
Disk: /dev/rwd0d
NetBSD disklabel disk geometry:
cylinders: 969021, heads: 16, sectors/track: 63 (1008 sectors/cylinder)
total sectors: 976773168

BIOS disk geometry:
cylinders: 1024, heads: 255, sectors/track: 63 (16065 sectors/cylinder)
total sectors: 976773168

Partitions aligned to 2048 sector boundaries, offset 2048

Partition table:
0: unknown (sysid 39)
    start 2048, size 3072000 (1500 MB, Cyls 0-191/89/26)
1: NTFS, OS/2 HPFS, QNX2 or Advanced UNIX (sysid 7)
    bootmenu: Windows
    start 3074048, size 104857600 (51200 MB, Cyls 191/89/27-6718/110/48), Active
2: OS/2 BM: hidden IFS (sysid 23)
    start 949954560, size 26818560 (13095 MB, Cyls 59131/238/52-60801/80/15)
3: NetBSD (sysid 169)
    bootmenu: NetBSD
    start 107931648, size 842022912 (411144 MB, Cyls 6718/110/49-59131/238/51)
        PBR is not bootable: All bytes are identical (0xaa)
Bootselector enabled, timeout 10 seconds.
First active partition: 1
Drive serial number: 3858897204 (0xe6021934)

i.e., same as the mbrlabel:

#        size    offset     fstype [fsize bsize cpg/sgs]
 a:   3072000      2048    unknown                     # (Cyl.      2*-   3049*)
 b: 104857600   3074048       NTFS                     # (Cyl.   3049*- 107075*)
 c: 842022912 107931648     unused      0     0        # (Cyl. 107075*- 942415*)
 d: 976773168         0     unused      0     0        # (Cyl.      0 - 969020)
 e:  26818560 949954560    unknown                     # (Cyl. 942415*- 969020*)

PBR is obviously not bootable: I haven't been able disklabel it yet.

Just to try an even simpler test:

# cat /etc/disktab
test:\
:dt=ESDI:se#512:ns#63:nt#16:sc#1008:nc#969021:\
:pa#842022912:oa#107931648:ta=4.2BSD:ba#0:fa#0:\
:pc#842022912:oc#107931648:\
:pd#976773168:od#0:
# disklabel -w -r -v wd0 test
# echo $?
0
# disklabel -r -t wd0
test|Automatically generated label:\
        :dt=ESDI:se#512:ns#63:nt#16:sc#1008:nc#969021:

I can't think of a simpler test... and can't spot the typo if there is one...


Cheers,

Patrick


Home | Main Index | Thread Index | Old Index