Port-mips archive

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

Re: ERLITE-3 boot problems




> On Aug 17, 2020, at 7:55 PM, Simon Burge <simonb%NetBSD.org@localhost> wrote:
> 
> Brook Milligan wrote:
> 
>> I am trying to install NetBSD-9 on an ERLITE-3.  I have the NetBSD
>> ERLITE kernel and md5 file in the MSDOS partition of the USB drive.  I
>> have a second partition (type 169/NetBSD) that contains a whole NetBSD
>> system.  The boot loader finds the kernel, loads it, and transfers
>> control.  The kernel probes all the devices, but fails to find the
>> root device.  All this is in the console output below, which is the
>> same regardless of whether or not the NetBSD partition is marked
>> active.
>> 
>> I fear I set this up wrong somehow and would appreciate any guidance.
>> How is the kernel supposed to find a root device different from the
>> boot device?  Does the partition need to be marked somehow?  Must
>> there be a boot loader?  Are there size constraints on the root
>> partition?
> 
> I don't have a USB drive in my erlite right now.  Did you use the USB drive
> that came with the erlite and use the existing partition layout or build a fresh
> USB drive?

I have tried several things, all starting with copying the original USB drive to a new one.  By the way, the new copy works fine booting EdgeOS, so the drive seems fine.

On the new copy I have tried each of the following, all on an NetBSD-9/amd64 machine:

- Replace the kernel/md5 files on the MSDOS partition with NetBSD equivalents, switched the other partition to NetBSD, and untarred some sets.  I have written the new disklabel both with -B be and without, i.e., with little endian.  I have not messed with the other options controlling the disklabel.  How should the disklabel be written in this case?  (By the way, what is the netbsd_elf32 kernel; I have been using netbsd?)

- Similar to above but created a larger NetBSD partition, i.e., did not just change the partition id.

- Similar to above but tried writing the disklabel with -M evbmips.  I think this trashed the MBR, but I'm not sure and haven't really investigated.

> Also, can you try "fdisk sdN" and "disklabel sdN" on that USB drive on
> another NetBSD system?

This is what I have been doing.  I have been doing all the USB manipulation on a NetBSD-9/amd64 machine.  I think you are wondering what the output is, though.  See below for one of the instances.  I have also tried making the NetBSD part of the disk the whole thing other than the MSDOS part, and also with no swap.  None of that seems to matter.

The "fabricating a geometry" message I'm getting from the kernel suggests that the disklabel is in the wrong place or otherwise messed up.  That should not normally appear, right?  Could that be the case?  What command options should I be using to write the label?

> If you don't mind using -current instead of NetBSD 9 Jared has made an
> image that you can dd(1) on to your USB then it magically resizes the
> rootfs up to the USB drive size on first boot:

Thanks.  I hadn't seen that, but will give it a try.  How was this made?

Cheers,
Brook




Disk: /dev/rsd0
NetBSD disklabel disk geometry:
cylinders: 118152, heads: 64, sectors/track: 32 (2048 sectors/cylinder)
total sectors: 241975296, bytes/sector: 512

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

Partitions aligned to 2048 sector boundaries, offset 2048

Partition table:
0: Primary DOS with 32 bit FAT - LBA (sysid 12)
    start 2048, size 290816 (142 MB, Cyls 0-18/58/40)
1: NetBSD (sysid 169)
    start 292864, size 7612416 (3717 MB, Cyls 18/58/41-492/20/40)
        PBR is not bootable: All bytes are identical (0x00)
2: <UNUSED>
3: <UNUSED>
No active partition.
Drive serial number: 2574516736 (0x99740200)


# /dev/rsd0:
type: SCSI
disk: USB DISK 3.0    
label: root
flags:
bytes/sector: 512
sectors/track: 32
tracks/cylinder: 64
sectors/cylinder: 2048
cylinders: 118152
total sectors: 241975296
rpm: 3600
interleave: 1
trackskew: 0
cylinderskew: 0
headswitch: 0           # microseconds
track-to-track seek: 0  # microseconds
drivedata: 0 

6 partitions:
#        size    offset     fstype [fsize bsize cpg/sgs]
 a:   3418112    292864     4.2BSD      0     0     0  # (Cyl.    143 -   1811)
 b:   4194304   3710976       swap                     # (Cyl.   1812 -   3859)
 c:   7612416    292864     unused      0     0        # (Cyl.    143 -   3859)
 d: 241975296         0     unused      0     0        # (Cyl.      0 - 118151)
 e:    290816      2048      MSDOS                     # (Cyl.      1 -    142)




Home | Main Index | Thread Index | Old Index