Slackware ARM on a Raspberry Pi

Information on available drives

You're going to need some information about your Linux system, and the available drives, in order to make new partitions. The easiest way to get the information you need is with the 'fdisk -l' command, like this:

The top device '/dev/mmcblk0' is our 32Gb microSD card. Notice that '/dev/mmcblk0p1' is the FAT32 partition where our boot files are located. The bottom device, '/dev/sda', is the 16Gb USB memory stick containing our Slackware ARM source media '/dev/sda1' partition. On your own system it may be different (i.e. /dev/sdb1).

If you're not using a USB stick as your Slackware SOURCE then you can ignore the instructions relating to it when following this tutorial.

The cfdisk partition manager

Now you need to setup the required partitions on your microSD card. You will do this using 'cfdisk' which is a command line partition manager in Linux. Remember your microSD card is '/dev/mmcblk0' and this is the drive we tell cfdisk to use. So, go ahead and type the command:

root@slackware:~# cfdisk /dev/mmcblk0

On your microSD card you will see a vfat (FAT32) partition already present, as in the example below.

The vfat (FAT32) partition 'mmcblk0p1' is fine as it is. In the example screenshot the size of the vfat partition is 91.6MB but this size changes from time to time so bear that in mind if yours is different. You're going to use the existing vfat partition as your boot partition but you're also going to need additional partitions in order to house your Linux system. So, at this point you should create a swap partition and a root partition.

Create a swap partition like this:

• Move the highlight down to the Free Space, using the cursor keys on your keyboard.
• select [ New ] at the bottom, and then press the enter key.
• When asked to specify Partition size type 512M and press the enter key. You can enter your own size if you prefer; 256M, 128M
• Select [ Primary ] and press the enter key.

Your new partition has been created. Now you need to tell cfdisk that this partition is going to be used as a swap file. At the bottom of the screen move the highlight to [ Type ] and make sure that 'mmcblk0p2' (the 512M partition) is the one still highlighted. Then press the enter key.

You will see the next screen below. You need to move the highlighter to '82 Linux swap' before pressing enter to save/close back to the cfdisk partition management screen.

This should have set the Partition Type to 'Linux swap' and if you can see that then all is good.

Now you need to create the root partition and we do it in much the same way as before:

• Move the highlight down to the Free Space
• select [ New ] at the bottom, and then press the enter key.
• When asked to specify Partition size just press the enter key to use all of the remaining free space.
• Select [ Primary ] and press the enter key.

So, if your screen is similar to the one above (given that you may have used a different size microSD card) then it's looking very good. The last thing you can do is set the boot partiton as 'bootable'. This is easier done than said by moving the highlight up to 'mmcblk0p1' (the vfat partition) and selecting [ Bootable ] at the bottom, and then pressing the enter key. Incidentally, making this partition 'bootable' is not required to make the Raspberry Pi boot into Slackware, but it's good practice to do it anyway.

You should have a vfat boot partition, a swap partition (of the size you've selected), and the rest of the space on your microSD card for your root partition. On our system we have quite a large root partition and this is more than adequate space on which to install Slackware ARM. Just make sure there's more than 10Gb allocated to your root partition if you're planning for full install. In the example below, you can see our partition table layout and that we've set the Boot flag on our 'mmcblk0p1' boot partition. So now you need to save these settings.

Save the new partition table to disk settings by selecting [ Write ] at the bottom and typing the word 'yes' when asked to save the changes, then pressing the enter key.

Disclaimer: The SARPi project website is for non-commercial and general information purposes only. The content is provided by FatDog.NL and while we endeavour to keep the information up to date and correct, we make no representations or warranties of any kind, express or implied, about the completeness, accuracy, reliability, suitability or availability with respect to the website or any information, software, products, services, or related graphics which is available on the website for any purpose. Any reliance you place on such information is therefore strictly at your own risk. In no event will we be liable for any loss or damage including without limitation, indirect or consequential loss or damage, or any loss or damage whatsoever arising from loss of data or profits arising out of, or in connection with, the use of this website or any of its contents. Through this website you are able to link to other websites which are not under the control of FatDog.NL. We have no control over the nature, content and availability of those sites. The inclusion of any links does not necessarily imply a recommendation or endorsement of any content within them. Every effort is made to ensure the SARPi website remains accessible. However, FatDog.NL takes no responsibility for, and will not be liable for, the SARPi website being temporarily unavailable due to technical issues beyond our control. FatDog.NL is in no way affiliated with Slackware Linux, Inc, or the Linux Foundation, or the Raspberry Pi Foundation, or any of their members, trustees, partners, or associates.