DaemonForums  

Go Back   DaemonForums > NetBSD > NetBSD General

NetBSD General Other questions regarding NetBSD which do not fit in any of the categories below.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 25th November 2008
kasse kasse is offline
Fdisk Soldier
 
Join Date: Jun 2008
Posts: 67
Thanked 0 Times in 0 Posts
Default fdisk -B does not rewrite the mbr

I have two hard disk, ad0 with freebsd and ad1 with netbsd.

Today I installed a second version of Netbsd on ad1s2 to try things on.
So on ad1 there was ad1s1 old netbsd ad1s2 new netbsd.
The problem is that when I use chainload to read the PBR of the partitions it always loads the same kernel so I guess that it reads the same second stage boot loader /boot. Because:

When I try find /netbsd I get
Code:
(hd1,0,a)
(hd1,1,a)
Then no matter which root (hd1,0,a) or (hd1,1,a) I choose and use:
Code:
 kernel /netbsd
on, the found kernels are one and the same - the one for the new netbsd. Somehow I cannot get to the kernel of the old netbsd on slice 1

How do I set the PBR to point to the correct second stage boot loaders?
Does anyone know of a guide similar to http://www.openbsd.org/faq/faq14.html#Boot386 for NetBSD?

Just for some extra info here is the output of fdisk and disklabel:

fdisk
Code:
Disk: /dev/rwd1d
NetBSD disklabel disk geometry:
cylinders: 620181, heads: 16, sectors/track: 63 (1008 sectors/cylinder)
total sectors: 625142448

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

Partition table:
0: NetBSD (sysid 169)
    start 63, size 40960017 (20000 MB, Cyls 0/1/1-2549/164/63), Active
        beg: cylinder    0, head   3, sector 16
        end: cylinder 1023, head  62, sector 16
        PBR appears to be bootable
1: NetBSD (sysid 169)
    start 40961088, size 20480544 (10000 MB, Cyls 2549/181/1-3824/143/63)
        beg: cylinder 1023, head   0, sector  1
        end: cylinder 1023, head  62, sector 16
        PBR appears to be bootable
2: NetBSD (sysid 169)
    start 61441632, size 20480544 (10000 MB, Cyls 3824/144/1-5099/106/63)
        beg: cylinder 1023, head   0, sector  1
        end: cylinder 1023, head  62, sector 16
        PBR appears to be bootable
3: <UNUSED>
Bootselector disabled.
Drive serial number: -554148968 (0xdef85b98)
and disklabel
Code:
# /dev/rwd1d:
type: unknown
disk: SEG320
label: 
flags:
bytes/sector: 512
sectors/track: 63
tracks/cylinder: 16
sectors/cylinder: 1008
cylinders: 620181
total sectors: 625142448
rpm: 3600
interleave: 1
trackskew: 0
cylinderskew: 0
headswitch: 0		# microseconds
track-to-track seek: 0	# microseconds
drivedata: 0 

16 partitions:
#        size    offset     fstype [fsize bsize cpg/sgs]
 a:   1049328  61441632     4.2BSD   1024  8192     0  # (Cyl.  60954 -  61994)
 b:   2097648  62490960       swap                     # (Cyl.  61995 -  64075)
 c:  40960017        63     unused      0     0        # (Cyl.      0*-  40634)
 d: 625142448         0     unused      0     0        # (Cyl.      0 - 620180)
 e:  15235920  64588608     4.2BSD   2048 16384     0  # (Cyl.  64076 -  79190)
 f:   2097648  79824528     4.2BSD   2048 16384     0  # (Cyl.  79191 -  81271)
Within netbsd I can only see the other partitions on wd1 with fdisk, but I cannot mount them like I can in freebsd by mounting slices, because I don't know how to specify the slices. I can only specify the wd1a-p (where I understand c is netbsd partition and d is whole disk) and not partitions or slices.

Since I admit that I do not understand either file system, there are probably things that are not true in the above, but it seems like I am able to navigate in the freebsd with my distorted/faulty perception of the matters.

Last edited by kasse; 27th November 2008 at 11:05 AM.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
fdisk Question Crotalus FreeBSD Installation and Upgrading 2 10th February 2010 08:10 AM
backup fdisk partitions gosha OpenBSD General 17 16th July 2009 03:19 AM
external drive partition question + fdisk question gosha OpenBSD General 15 15th June 2009 02:00 PM
fdisk can't see (Vista) ntfs partitions caesius FreeBSD General 7 23rd September 2008 01:01 AM
FreeBSD equivalent of DOS's fdisk /mbr Nobber FreeBSD General 5 3rd June 2008 07:19 AM


All times are GMT. The time now is 02:19 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick