Upgrading from NetBSD 5.1 to 10_RC1
NetBSD 5.1 on a 1998 laptop
I still have my old 1998 Toshiba Sattelite Pro 445 CDT with 81MB (yep, 0.08GB) of RAM and the original 1GB HD. I still have a working 3Com PCMCIA NIC but the FD adapter and CDROM bay have long since died.
It's running a 2010 build of NetBSD 5.1 (i386) generally pretty well. It's hard to get any pkgsrc working anymore so it's been static (e.g. Python 2.6.6 😂). I have to use curl or lynx for anything http related. I can run X11. I definitely do not have it attached directly to the internet.
Often during the holiday break time of year I take these old hardware devices out for a spin. This time I tried to upgrade the old laptop from NetBSD 5.1 to 10_RC1. Without the FD or CDROM drives, I could not use a floppy or CD to boot an install image. The BIOS can't do PXE or recognize a USB device to boot.
Here are some notes to share on getting 10_RC1 and 9.3 to boot.
NetBSD 10_RC1 on 90s hardware
The key takeaway is that NetBSD 10_RC1 does not run well on this old Intel 586-class @132 MHz device -- but it does run and I got it stable. I also gave NetBSD 9.3 a try with similar results.
When I needed to copy a lot of files, I used a modern machine running NetBSD 9.3 (AMD64). I was also able to a build a custom kernel on the same machine for 9.3. For 10_RC1, I hit some issues trying to trim GENERIC and gave up (maybe next winter with 10.1).
Without an install image to boot from, I kept 5.1 on the boot partition (existing HD) and had to use multiboot from the existing boot manager along with a USB thumb drive. Here are the steps for 10_RC1; substitude as needed for 9.3:
- On a modern device, prepare a USB thumb drive (mine was 2GB) for the 10_RC1 root partition and userland: Using
disklabel -i -I /dev/sd0
, create a swap b partition (I used 80MB) and at least a 4.2BSD a partition. Then do newfs /dev/rsd0a. Mount /dev/sd0a to /mnt. - Download the installation sets and
tar zxvfp
to /mnt/ at least kernel-GENERIC.tgz (as /netbsd), modules.tgz, and etc.tgz. I also added comp.tgz, man.tgz, misc.tgz, and text.tgz. This left me plenty of room on sd0a. - Add empty /proc and /kern directories.
- Create /etc/fstab with at least
/dev/sd0a / ffs rw 1 1
/dev/sd0b none swap sw 0 0
kernfs /kern kernfs rw
ptyfs /dev/pts ptyfs rw
procfs /proc procfs rw
- Edit rc.conf and set
rc_configured=YES
. - On the laptop, copy the GENERIC kernel to the laptop's 5.1 boot partion as /netbsd10.
- Edit the 5.1 /boot.cfg with an added menu:
menu=NetBSD10_RC1 on sd0a:multiboot netbsd10 root=sd0a console=pc
- Put in the USB thumb drive and reboot. When the boot manager prompts, select the new NetBSD10_RC1 menu. It takes a few minutes to boot.
- Log in as
root
and runsysinst
to complete configuration, including the network. I also enabled sshd. - Once happy with how things are configured, reboot again to confirm.
At this point, I was able to do pkg_add and install some minimal tools, including tmux (dearly missed on my 5.1 partition).
Additional notes
The dmesg is below.
I first tried using a PCMCIA CF adapter with a comfy 8GB CF card instead of a USB thumb drive. Unfortunately, I started hitting PCMCIA issues ("wdc2:0:0: lost interupt") and I switched to using a USB thumb drive.
The laptop feels slower on both 10_RC1 and 9.3. Without more trimming of the kernel, there's a lot more use of the swap drive.
Summary
That was a fun little project and along the way I learned some things about the NetBSD init process and boot manager.
I'll stick to NetBSD 5.1 on this 90s laptop for now. It was a great release back then. And I will enjoy NetBSD 10 on my Aarch64 devices -- great release for nowadays 😊
[ 1.000000] multiboot: Information structure flags: 0x0000000d
[ 1.000000] multiboot: Command line: netbsd10 root=sd0a console=pc
[ 1.000000] multiboot: 639 KB lower memory, 81024 KB upper memory
[ 1.000000] Copyright (c) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
[ 1.000000] 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013,
[ 1.000000] 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021, 2022, 2023
[ 1.000000] The NetBSD Foundation, Inc. All rights reserved.
[ 1.000000] Copyright (c) 1982, 1986, 1989, 1991, 1993
[ 1.000000] The Regents of the University of California. All rights reserved.
[ 1.000000] NetBSD 10.0_RC1 (GENERIC) #0: Sun Nov 5 18:30:08 UTC 2023
[ 1.000000] mkrepro@mkrepro.NetBSD.org:/usr/src/sys/arch/i386/compile/GENERIC
[ 1.000000] total memory = 81660 KB
[ 1.000000] avail memory = 59264 KB
[ 1.000000] timecounter: Timecounters tick every 10.000 msec
[ 1.000000] Kernelized RAIDframe activated
[ 1.000000] timecounter: Timecounter "i8254" frequency 1193182 Hz quality 100
[ 1.000004] mainbus0 (root)
[ 1.000004] Firmware Error (ACPI): A valid RSDP was not found (20221020/tbxfroot-275)
[ 1.000004] autoconfiguration error: acpi_probe: failed to initialize tables
[ 1.000004] ACPI Error: Could not remove SCI handler (20221020/evmisc-316)
[ 1.000004] cpu0 at mainbus0
[ 1.000004] ACPI Error: AE_BAD_PARAMETER, Thread 3242920000 could not acquire Mutex [ACPI_MTX_Tables] (0x2) (20221020/utmutex-326)
[ 1.000004] ACPI Error: Mutex [ACPI_MTX_Tables] (0x2) is not acquired, cannot release (20221020/utmutex-367)
[ 1.000004] cpu0: Use cpuid to serialize rdtsc
[ 1.000004] cpu0: Intel 586-class, 132MHz, id 0x543
[ 1.000004] cpu0: node 0, package 0, core 0, smt 0
[ 1.000004] pci0 at mainbus0 bus 0: configuration mode 1
[ 1.000004] pci0: i/o space, memory space enabled, rd/line, rd/mult, wr/inv ok
[ 1.000004] pchb0 at pci0 dev 0 function 0: Toshiba Host Bridge/Controller (rev. 0x27)
[ 1.000004] vga0 at pci0 dev 4 function 0: Chips and Technologies 65554 (rev. 0xc2)
[ 1.000004] wsdisplay0 at vga0 kbdmux 1: console (80x25, vt100 emulation)
[ 1.000004] wsmux1: connecting to wsdisplay0
[ 1.000004] drm at vga0 not configured
[ 1.000004] ohci0 at pci0 dev 11 function 0: NEC USB Host Controller (rev. 0x01)
[ 1.000004] ohci0: interrupting at irq 11
[ 1.000004] ohci0: OHCI version 1.0
[ 1.000004] usb0 at ohci0: USB revision 1.0
[ 1.000004] isa0 at mainbus0
[ 1.000004] lpt0 at isa0 port 0x378-0x37b irq 7
[ 1.000004] com0 at isa0 port 0x3f8-0x3ff irq 4: ns16550a, 16-byte FIFO
[ 1.000004] com1 at isa0 port 0x2f8-0x2ff irq 3: ns16550a, 16-byte FIFO
[ 1.000004] pckbc0 at isa0 port 0x60-0x64
[ 1.000004] pckbd0 at pckbc0 (kbd slot)
[ 1.000004] pckbc0: using irq 1 for kbd slot
[ 1.000004] wskbd0 at pckbd0: console keyboard, using wsdisplay0
[ 1.000004] pms0 at pckbc0 (aux slot)
[ 1.000004] pckbc0: using irq 12 for aux slot
[ 1.000004] wsmouse0 at pms0 mux 0
[ 1.000004] attimer0 at isa0 port 0x40-0x43
[ 1.000004] wdc0 at isa0 port 0x1f0-0x1f7 irq 14
[ 1.000004] atabus0 at wdc0 channel 0
[ 1.000004] wdc1 at isa0 port 0x170-0x177 irq 15
[ 1.000004] atabus1 at wdc1 channel 0
[ 1.000004] sb0 at isa0 port 0x220-0x237 irq 5 drq 1: dsp v3.01
[ 1.000004] audio0 at sb0: playback, capture, half duplex
[ 1.000004] audio0: slinear_le:16 -> ulinear_le:8 2ch 20000Hz, blk 400 bytes (10ms) for playback
[ 1.000004] audio0: slinear_le:16 <- ulinear_le:8 2ch 20000Hz, blk 400 bytes (10ms) for recording
[ 1.000004] midi0 at sb0: SB MIDI UART
[ 1.000004] opl0 at sb0: model OPL3
[ 1.000004] midi1 at opl0: SB Yamaha OPL3
[ 1.000004] wss0 at isa0 port 0x530-0x537 irq 10 drq 0,1: CS4231
[ 1.000004] audio1 at wss0: playback, capture, full duplex
[ 1.000004] audio1: slinear_le:16 2ch 48000Hz, blk 1920 bytes (10ms) for playback
[ 1.000004] audio1: slinear_le:16 2ch 48000Hz, blk 1920 bytes (10ms) for recording
[ 1.000004] pcppi0 at isa0 port 0x61
[ 1.000004] midi2 at pcppi0: PC speaker
[ 1.000004] sysbeep0 at pcppi0
[ 1.000004] isapnp0 at isa0 port 0x279
[ 1.000004] fdc0 at isa0 port 0x3f0-0x3f7 irq 6 drq 2
[ 1.000004] pcic0 at isa0 port 0x3e0-0x3e1 iomem 0xd0000-0xdffff irq
[ 1.000004] pcic0: controller 0 (Intel 82365SL Revision 1) has sockets A and B
[ 1.000004] pcmcia0 at pcic0 controller 0 socket 0
[ 1.000004] pcmcia1 at pcic0 controller 0 socket 1
[ 1.000004] attimer0: attached to pcppi0
[ 1.000004] isapnp0: no ISA Plug 'n Play devices found
[ 1.000004] WARNING: system needs entropy for security; see entropy(7)
[ 1.013921] timecounter: Timecounter "clockinterrupt" frequency 100 Hz quality 0
[ 1.015488] timecounter: Timecounter "TSC" frequency 132717780 Hz quality 3000
[ 1.034626] fd0 at fdc0 drive 0: 1.44MB, 80 cyl, 2 head, 18 sec
[ 1.034626] pcic0: controller 0 detecting irqs with mask 0xdeb8:..9
[ 1.034626] pcic0: autoconfiguration error: can't share irq with cards; polling for socket events
[ 1.034626] autoconfiguration error: pcic0: WARNING: powerhook_establish is deprecated
[ 1.034626] autoconfiguration error: pcic0: WARNING: powerhook_establish is deprecated
[ 1.054630] uhub0 at usb0: NetBSD (0x0000) OHCI root hub (0x0000), class 9/0, rev 1.00/1.00, addr 1[ 1.054630] uhub0: 2 ports with 2 removable, self powered
[ 1.064617] IPsec: Initialized Security Association Processing.
[ 1.534286] ep0 at pcmcia0 function 0: <3Com, Megahertz 574B, B, 001>
[ 1.534286] pcic0: port 0x400-0x41f
[ 1.534286] pcmcia0: card irq 9
[ 1.544312] ep0: address 00:50:04:fd:31:c2, 64KB word-wide FIFO, 1:1 Rx:Tx split
[ 1.554306] tqphy0 at ep0 phy 0: 78Q2120 10/100 media interface, rev. 10
[ 1.554306] tqphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto
[ 2.353764] wdc2 at pcmcia1 function 0: <SanDisk, SDP, 5/3 0.6>
[ 2.353764] pcic0: port 0x420-0x42f
[ 2.353764] wdc2: i/o mapped mode
[ 2.353764] pcmcia1: card irq 9
[ 2.643620] umass0 at uhub0 port 1 configuration 1 interface 0
[ 2.643620] umass0: SMI Corporation (0x090c) USB DISK (0x1000), rev 2.00/11.00, addr 2
[ 2.643620] umass0: using SCSI over Bulk-Only
[ 2.653603] scsibus0 at umass0: 2 targets, 1 lun per target
[ 2.853447] atabus2 at wdc2 channel 0
[ 2.893435] sd0 at scsibus0 target 0 lun 0: <SMI, USB DISK, 1100> disk removable
[ 2.913423] sd0: 1920 MB, 3936 cyl, 16 head, 63 sec, 512 bytes/sect x 3932160 sectors
[ 4.162614] wd0 at atabus0 drive 0
[ 4.172637] wd0: <IBM-DMCA-21215>
[ 4.172637] wd0: drive supports 16-sector PIO transfers, LBA addressing
[ 4.172637] wd0: 1160 MB, 2358 cyl, 16 head, 63 sec, 512 bytes/sect x 2376864 sectors
[ 4.292562] wd0: drive supports PIO mode 4, DMA mode 1
[ 4.292562] atapibus0 at atabus1: 2 targets
[ 1.034626] fd0 at fdc0 drive 0: 1.44MB, 80 cyl, 2 head, 18 sec
[ 1.034626] pcic0: controller 0 detecting irqs with mask 0xdeb8:..9
[ 1.034626] pcic0: autoconfiguration error: can't share irq with cards; polling for socket events
[ 1.034626] autoconfiguration error: pcic0: WARNING: powerhook_establish is deprecated
[ 1.034626] autoconfiguration error: pcic0: WARNING: powerhook_establish is deprecated
[ 1.054630] uhub0 at usb0: NetBSD (0x0000) OHCI root hub (0x0000), class 9/0, rev 1.00/1.00, addr 1[ 1.054630] uhub0: 2 ports with 2 removable, self powered
[ 1.064617] IPsec: Initialized Security Association Processing.
[ 1.534286] ep0 at pcmcia0 function 0: <3Com, Megahertz 574B, B, 001>
[ 1.534286] pcic0: port 0x400-0x41f
[ 1.534286] pcmcia0: card irq 9
[ 1.544312] ep0: address 00:50:04:fd:31:c2, 64KB word-wide FIFO, 1:1 Rx:Tx split
[ 1.554306] tqphy0 at ep0 phy 0: 78Q2120 10/100 media interface, rev. 10
[ 1.554306] tqphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto
[ 2.353764] wdc2 at pcmcia1 function 0: <SanDisk, SDP, 5/3 0.6>
[ 2.353764] pcic0: port 0x420-0x42f
[ 2.353764] wdc2: i/o mapped mode
[ 2.353764] pcmcia1: card irq 9
[ 2.643620] umass0 at uhub0 port 1 configuration 1 interface 0
[ 2.643620] umass0: SMI Corporation (0x090c) USB DISK (0x1000), rev 2.00/11.00, addr 2
[ 2.643620] umass0: using SCSI over Bulk-Only
[ 2.653603] scsibus0 at umass0: 2 targets, 1 lun per target
[ 2.853447] atabus2 at wdc2 channel 0
[ 2.893435] sd0 at scsibus0 target 0 lun 0: <SMI, USB DISK, 1100> disk removable
[ 2.913423] sd0: 1920 MB, 3936 cyl, 16 head, 63 sec, 512 bytes/sect x 3932160 sectors
[ 4.162614] wd0 at atabus0 drive 0
[ 4.172637] wd0: <IBM-DMCA-21215>
[ 4.172637] wd0: drive supports 16-sector PIO transfers, LBA addressing
[ 4.172637] wd0: 1160 MB, 2358 cyl, 16 head, 63 sec, 512 bytes/sect x 2376864 sectors
[ 4.292562] wd0: drive supports PIO mode 4, DMA mode 1
[ 4.292562] atapibus0 at atabus1: 2 targets
[ 4.302566] cd0 at atapibus0 drive 0: <TOSHIBA CD-ROM XM-1502BN, 1200002133, 1001> cdrom removable
[ 4.302566] cd0: drive supports PIO mode 3, DMA mode 1
[ 4.302566] wd1 at atabus2 drive 0
[ 4.302566] wd1: <SanDisk SDCFH-004G>
[ 4.302566] wd1: drive supports 1-sector PIO transfers, LBA48 addressing
[ 4.302566] wd1: 3815 MB, 7751 cyl, 16 head, 63 sec, 512 bytes/sect x 7813120 sectors
[ 4.322534] wd1: drive supports PIO mode 4
[ 4.622318] swwdog0: software watchdog initialized
[ 4.712302] pcmcia1: card irq 9
[ 5.411819] pcmcia1: card irq 9
[ 5.901510] entropy: best effort
[ 5.941481] pcmcia1: card irq 9
[ 6.551118] WARNING: 4 errors while detecting hardware; check system log.
[ 6.551118] boot device: sd0
[ 6.581099] root on sd0a dumps on sd0b
[ 6.681039] root file system type: ffs
[ 6.710997] kern.module.path=/stand/i386/10.0/modules
[ 37.841280] pcmcia0: card irq 9
[ 70.960240] wsdisplay0: screen 1 added (80x25, vt100 emulation)
[ 71.000217] wsdisplay0: screen 2 added (80x25, vt100 emulation)
[ 71.030195] wsdisplay0: screen 3 added (80x25, vt100 emulation)
[ 71.060181] wsdisplay0: screen 4 added (80x25, vt100 emulation)
[ 296.517085] pcmcia1: card irq 9
[ 297.046716] pcmcia1: card irq 9
[ 297.636370] pcmcia1: card irq 9