Disk Preparation
Linux supports SCSI or IDE disk controllers and drives, or a combination of thereof.
The first step of installing Linux is to prepare several disk partitions. A partition is a continuous region of the disk set aside to contain a filesystem. In order to run Linux, you should provide at least two disk partitions. They are:
Since Linux is based upon a virtual memory model, programs requiring memory beyond your actual physical RAM cause 'unused' programs and data to be temporarily swapped out to a disk swapfile. This allows you to run programs that use more memory that you actually have, but there is a significant price to pay in terms of system performance when this happens. This is why its so important to have as much RAM installed in your system as you can afford.
In general the swap partition should be at about twice as large as the amount of memory installed in your machine.
The primary linux partition will contain all the directories and files required by users and the operating system. This partition should be large enough for the OS and any additional programs and data you expect to use.
Advanced Linux-ers usually subdivide the linux 'root' volume into several sub-partitions, however beginners do not need to worry about such things just yet....
~~~ ~~~ |
Regarding AFFS partitions: Linux will not install correctly if any of your AFFS partitions have the option enabled. The AmigaDos 3.1 manuals state that DirCache is only useful with floppy-disks and very slow hard-disks. In general you should never use the DirCache option on harddisks- you are simply wasting memory that could be put to good use elsewhere. The afdisk program used by the Linux installer also has problems with AFFS DirCache partitions. Anyway, double-check all of your existing partitions and keep in mind that changing any partition option will destroy all data currently on that partition. (This is a warning in case you missed it). |
While creating IDE disk partitions on my A4000 (with 3.0 ROMs), I had to limit the maxtransfer value to 0xfffe or AmigaDos would corrupt the filesystem and eventually crash. This problem is not present in 3.1 ROMs. |
I won't explain all the gory details, but there are several methods to prepare your hard disk(s) for Linux:
AmigaDos HDToolBox program.
The AmigaDos HDToolBox program has been available since 2.04 or so. HDToolBox is my preferred disk partitioning tool under AmigaDos. Other programs such as FaastPrep are unnecessary since HDToolBox provides the same functionality without all the limitations and quirks.
afdisk program provided by the RedHat installer.
The RedHat installers afdisk works fine as long as you don't have any DirCache partitions. Its not quite as friendly as x86 fdisk since it doesn't keep track of where previous partitions end, and it requires you to specify disk cylinders directly, instead of simply entering lengths in Kb or Mb.
Disk preparation programs from AmiNet, or bundled with your disk controller such as FaastPrep.
You may have varying degrees of success with these programs. Send me a note if you find one that does, or does not work.
If you do not have sufficient contiguous free space on your current drive you must (in order of risk/difficulty):
Hints:
To increase system performance, place swap on a different physical disk drive than your primary linux disk(s) if possible.
This reduces thrashing while swapping and lets you determine swap usage at-a-glance if you have a disk activity LED on your swap volume. If possible, make sure you place swap on your fastest hard disk.
Try to keep at least one regular Amiga AFFS/OFS partition around so you can easily exchange files between AmigaDos and Linux.
You do not need to format the Linux disk volumes under AmigaDos because Linux will do this during the install process.
Screenshot of my HDToolBox mainscreen:
This is HDToolBox's main screen. Note that on my A4000 the SCSI shown in the upper-left is a 'white-lie'; the drive is actually IDE, but due to an odd twist of history AmigaDos uses the scsi.device device-driver to access the IDE disks.
Screenshot of my HDToolBox drive-type definition screen:
If you add a new hard disk to your system you should enter this screen and click on the
Read Configuration button to retrieve the drive geometry. If you run HDToolBox from a boot floppy you'll need to write-enable it because HDToolBox saves this information for later use.There are two issues to note on this screen. I have disabled the Supports Reselection checkbox because my drive is IDE (IDE does not support reselection as most SCSI drives do), and the displayed drive capacity is shown to be negative!. I've seen this HDToolBox problem on large drives before, and in some cases I've had to manually calculate cyl/head/sect values that result in a positive capacity. The negative value reported on this screen does not seem to be causing any (obvious) problems, so I'll ignore it (for now).
Here are screenshots of my
swap partition settings.Key points for swap partition:
Note that I specified a huge swap area, but you only need to reserve a value about double the amount of your system RAM, in bytes..
Here are screenshots of my primary
linux partition settings.Key points for linux partition:
And here is sample
afdisk and df output from one of my A2000's running RedHat m68k Linux:
Disk /dev/sda: 1 heads, 888 sectors, 2336 cylinders, RDB: 0 Logical Cylinders from 2 to 2335, 512 bytes/Cylinder Device Boot Mount Begin End Size Pri BBlks System /dev/sda1 * * 2 810 359196 -10 0 0x41465301 = AFS\1[unknown] /dev/sda2 811 2335 677100 0 0 0x4C4E5800 = LNX\0Linux native Disk /dev/sdb: 1 heads, 182 sectors, 3684 cylinders, RDB: 0 Logical Cylinders from 2 to 3683, 512 bytes/Cylinder Device Boot Mount Begin End Size Pri BBlks System /dev/sdb1 * * 2 3160 287469 -20 0 0x444F5303 = DOS\3Amiga FFS Int. /dev/sdb2 3161 3683 47593 0 0 0x53575000 = SWP\0Linux swap Disk /dev/sdc: 1 heads, 666 sectors, 1250 cylinders, RDB: 0 Logical Cylinders from 2 to 1249, 512 bytes/Cylinder Device Boot Mount Begin End Size Pri BBlks System /dev/sdc1 * * 2 310 102897 -30 0 0x444F5303 = DOS\3Amiga FFS Int. /dev/sdc2 311 1249 312687 0 0 0x4C4E5800 = LNX\0Linux native Output from Linux df command: Filesystem 1024-blocks Used Available Capacity Mounted on /dev/sdc2 302702 14939 272129 5% / /dev/sdb1 287468 250971 36497 87% /dh1 /dev/sdc1 102896 29 102867 0% /dh2 /dev/sda2 655436 211593 409988 34% /usr