NetBSD/amiga on Warp

Post Reply
User avatar
karloch
Posts: 5
Joined: Wed Aug 10, 2022 9:49 pm
Location: Spain
Contact:

NetBSD/amiga on Warp

Post by karloch »

While the AmigaOS is one of the biggest benefits of the Amiga computers, there are other operating systems available for our platform. At the time of writing these lines, current Linux kernel and NetBSD versions still -amazingly- work on the Amiga as long as you have a MMU enabled CPU and enough RAM. Warp accelerators exceed these requirements, meaning that as long as you have a full 68060, your are ready to run Linux or NetBSD.

Kudos to the team of people of the Linux/m68k, Debian/m68k and NetBSD/amiga community for their work keeping the Linux and NetBSD running on Amiga!

This post is about NetBSD/amiga.

What is NetBSD/amiga?

NetBSD/amiga is the port of NetBSD operating system to the Amiga line of personal computers by Commodore, Amiga International and to the DraCo by MacroSystem.

NetBSD is a current, up to date UNIX family operating system with an high degree of compatibility with Amiga hardware, multitasking, multiuser and advanced networking features. It comes with a rich set of system utilities, compilers, X11R7 and even games.

In contrast with GNU/Linux, where we have a kernel and different distributions for the userspace, NetBSD developers covers both, the kernel and the userspace under a single distribution. Notice this is not better or worse than the GNU/Linux approach.

You can watch this video captured from my Warp 1260 enabled Amiga 1200, running NetBSD.



Minimum requirements

If you have a Warp accelerator, you probably are way beyond the minimum requirements for running NetBSD:
  • 68020+68851, 68030, 68040 or 68060 CPU.
  • ECS or AGA chipset. There is also support for a good amount of RTG cards.
  • 24 MB of FAST MEM; way more if you plan to run X.
  • 250 MB of HDD available space. The HDD must be connected to a supported storage controller, such as the Gayle IDE, ELBOX FastATA 1200 or one of the multiple SCSI controllers supported.
Apart from the minimum requirements, you can find a list of Amiga supported devices here.

Networking

I consider networking an essential of any UNIX operating system, and NetBSD is no exception. Apart of several Ethernet controllers, NetBSD supports NE2000 compatible PCMCIA cards. I currently own a D-Link DE-660+ and a Fiberline FL-4680 that work well with both, AmigaOS through the cnet.device and NetBSD.

Specific notes for Warp

NetBSD/amiga doesn't support -at the time of writing these lines- Warp RTG, audio or wireless networking. However it will take full advantage of the 68060 -even more if you clock it beyond the 50 MHz- and the fast access to RAM. If your Amiga is a 1200 and you want to use the PCMCIA slot for a ethernet network card you will need to use WarpTool to set IDEMode in A1200 mode with WarpTool IDEMode=A1200 and attach your hard drive to the standard Amiga 1200 Gayle IDE port.

This guide continues in the next post!
User avatar
karloch
Posts: 5
Joined: Wed Aug 10, 2022 9:49 pm
Location: Spain
Contact:

Re: NetBSD/amiga on Warp

Post by karloch »

How to install

Installing a new OS on your Amiga can make you lose the data in your hard drive, follow these instructions AT YOUR OWN RISK; knowing what you are doing is gold, backing up your data is platinum. I really recommend to try the setup on a emulator such as WinUAE before doing it in your real Amiga.

Installation of NetBSD/amiga is not as hard as most people think it is, but it requires some knowledge about Amiga disk partitioning, Amiga CLI and UNIX. The high level steps to perform a install are:
  1. Installation media. You need the install media of the operating system. You can download the files from here or the ISO image. NetBSD supports CD-ROM drives connected to SCSI or ATAPI drives to the Gayle IDE. If you don't have a CD-ROM, you can have the installation files on a Amiga FFS partition or if you have network, using NFS or FTP.
  2. Partition the hard drive. The hard drive is partitioned using HDToolBox following the instructions here. I highly recommend that the swap and the root partitions to be below the first 4 GB boundary. Further partitions can be created beyond this limit.
  3. Write to miniroot filesystem to swap partition. Follow the instructions here. You will need to use the AmigaOS utility xstreamtodev included in the NetBSD install files to write the miniroot.fs image file to the swap partition. If I recall correctly, this tool doesn't support writing beyond the 4 GB boundary, so make sure your swap partition is within the limit. If you want to retry installation, this step must be repeated.
  4. Boot into NetBSD installation. Reboot your Amiga holding down the two mouse buttons to enter the Early Startup Menu and from the boot options, select the swap partition to boot from it. The NetBSD bootloader should appear, giving you the opportunity to change the boot options; if -A is present, the system will boot in dblPAL or dblNTSC mode (31kHz), but you can remove the parameter to make it boot in PAL or NTSC (15 kHz). Important note for Amiga OS 3.2 users: This step will fail in kickstart >= 47.96, but can still boot the operating system or the installation with the AmigaOS runbootblock or loadbsd utilities that can be found in the NetBSD install ISO at https://cdn.netbsd.org/pub/NetBSD/NetBS ... -amiga.iso, or at http://ftp.nluug.nl/os/BSD/NetBSD/arch/amiga/utils/. runbootblock syntax is runbootblock -d<device> -u<unit> -p<rdb-name>, ie. runbootblock -dscsi.device -u0 -pnetbsd-root.
  5. Install NetBSD. From here the actual install of NetBSD starts. Follow the on-screen instructions and the install documentation. Be very careful when selecting the partition to format as root and swap for your NetBSD operating system. If you want to install your system using NFS or FTP you will need your ethernet adapter detected and boot and properly configured when install script ask you about IP configuration (no DHCP supported on the install!). Whatever source of installation you choose, you will need to remember the path where the install files are stored. If everything went well you should be able to select packages and file unpack will begin.
  6. Run your new install. After file copy you will find yourself at the installation system command prompt. Write halt to shutdown this system and reboot into your actual install. When you see the login prompt you will be able to enter using the root account. There won't be a password until you set one with passwd. Congratulations! You have installed NetBSD on your Amiga.
Here you can see a WinUAE capture from the full install process. It emulates a SCSI CD-ROM drive as install media:

User avatar
karloch
Posts: 5
Joined: Wed Aug 10, 2022 9:49 pm
Location: Spain
Contact:

Re: NetBSD/amiga on Warp

Post by karloch »

Post-installation steps

Even after successful install of NetBSD on your Amiga, if you are not familiar with the OS you will have a lot of questions: how do I switch to white over black screen? How do I setup the software package manager? How do I start the GUI (X11) in color? Can enable SSH access to my Amiga?...

I have gathered multiple miscellaneous post-installation steps on this GitHub Gist.

A note on CF cards and NetBSD

I found that CF cards that works well in AmigaOS not necessarily work well in NetBSD, as many of them lack ATA commands used by the operating system. This can be checked with the command atactl wd0 identify In my case I was facing the following errors:

Code: Select all

[   486.702655] autoconfiguration error: wdc0:0:0: lost interrupt
[   486.714186]         type: ata tc_bcount: 41472 tc_skip: 24064
[   486.728095] wd0a: device timeout writing fsbn 5611343 of 5611296-5611423 (wd0 bn 7420703; cn 7361 tn 12 sn 59), xfer 1f30, retry 0
[   499.221228] wdc0:0:0: timeout waiting for DRQ, st=0x50, err=0x00
[   499.241306] wd0a: device timeout writing fsbn 5611296 of 5611296-5611423 (wd0 bn 7420656; cn 7361 tn 12 sn 12), xfer 1f30, retry 1
[   509.830048] wdc0:0:0: timeout waiting for DRQ, st=0x50, err=0x00
[   509.830048] wd0a: device timeout writing fsbn 5611296 of 5611296-5611423 (wd0 bn 7420656; cn 7361 tn 12 sn 12), xfer 1f30, retry 2
[   509.830048] wdc0:0:0: timeout waiting for DRQ, st=0x50, err=0x00
[   509.830048] wd0a: device timeout writing fsbn 5611296 of 5611296-5611423 (wd0 bn 7420656; cn 7361 tn 12 sn 12), xfer 1f30, retry 3
[   512.041365] wd0: soft error (corrected) xfer 1f30
After switching from a CF card to a mSATA drive with a mSATA to IDE adapter the problem was solved.

Have fun with UNIX on your Warp-enabled Amiga!
marmacc
Developer
Posts: 86
Joined: Sat Oct 16, 2021 7:06 pm
Location: Immenstadt i. Allgäu

Re: NetBSD/amiga on Warp

Post by marmacc »

Great Guide! Thank you for this.
Post Reply