Slackware ARM mini root filesystems ----------------------------------- This directory contains a mini root filesystem of Slackware ARM. There is just enough of the system to get you started with a working Slackware system, with either console access or remote console access (either a serial line login, or through SSH). Each filesystem expands to approximately 200MB in size. Target audience --------------- The mini root filesystems are aimed at developers or competent Linux administrators. This is because you will need to make modifications to the mini root file system and partition your disc/storage manually. In some instances, if you will be installing the mini root onto a flash device, you'll need to use the appropriate tools to do so. Purpose ------- The purpose of these mini roots are to provide a Slackware system that contains the essential system packages. The primary goals are: - To provide an easy method of bootstrapping Slackware ARM onto a new ARM Hardware Model. - To provide a spring board to build your new Slackware ARM installation if the installer is not available for your Hardware Model. - To provide a mini system for 'embedded device' (e.g. a WiFi access point) that will fit onto a 512MB NAND device. What's included? ---------------- The easiest way to see what is included is to look at the mini root build script: scripts/build_minirootfs.sh You will find a list of packages there. For miniroots of Slackware versions 14.0 or older, all of Slackware ARM's kernels and kernel modules are included. For releases of Slackware newer than 14.0, no kernel packages are present because for the Hardware Models that are supported by Slackware ARM, the proper installation method is to use the Slackware Installer: https://docs.slackware.com/slackwarearm:inst Details of the mini root file systems ------------------------------------- Each root filesystem is accompanied by a text file containing the: - root password - SSH RSA fingerprint - SHA1 SUM of the archive The text file is GPG signed with the Slackware ARM security key so that you can verify that the text file is how it should be, and that the MD5sum and SSH fingerprint is what it should be. How to use ----------- The mini root filesystems are presented as LZMA compressed tar archives. You can use "xz" (included in Slackware) to decompress it. In order to use it: As root on your Linux system, unpack the mini root into a temporary location: Unpack to a temporary directory: ```````````````````````````````` # mkdir /tmp/armminirootfs # cd /tmp ## (I assume you downloaded the archive into /tmp) # tar xf slackaarch64-current-miniroot_*.tar.xz -C /tmp/armminirootfs Update the fstab: ````````````````` You need to modify the fstab to suit your particular environment. You also may wish to setup a tmpfs /tmp, for example. # cd /tmp/armminirootfs # vi etc/fstab You may wish to switch off daemons such as syslog - especialy if you are writing this image to NAND. # chmod -x etc/rc.d/rc.syslog Serial login ```````````` Most Hardware Model's UART is /dev/ttyS0, but some (including the Raspberry Pi and the ARM Versatile system) use /dev/ttyAMA0. You can edit the lines below as appropriate. By default the mini root ships with a login spawning on the first serial terminal, ttyS0. This is to open a terminal line to provide the facility to login to the Operating System. This is essential for troubleshooting and development. If you're using this on another Hardware Model that does not have its console output directed to the serial port, or even testing this mini root under QEMU, you may wish to disable it to prevent "init" from throwing warnings if it cannot open a tty on ttyS0. # vi etc/inittab Find these lines, and comment out the line beginning with "s0": # Local serial lines: s0:12345:respawn:/sbin/agetty 115200 ttyS0 vt100 Allow root login on serial line 0: # sed -i 's?^#ttyS0?ttyS0?' etc/securetty SSH login `````````` By default OpenSSH does not allow root to login with a password. This is a security concern, so you should think about this carefully if your Hardware Model is connected directly to an untrusted network (such as the Internet!). You'd be better off making a user account, sshing into the machine as that user and escalating your privileges locally with "su" or "sudo". # sed -i 's?^#PermitRootLogin.*?PermitRootLogin yes?g' etc/ssh/sshd_config Console Key map: ```````````````` If you're not in the UK and your ARM Hardware Model has a keyboard attached, you will want to configure the keymap correctly: # vi etc/rc.d/rc.keymap Adjust network settings: ```````````````````````` # vi etc/rc.d/rc.inet1.conf By default eth0 is set to acquire its network address via DHCP. Wipe unnecessary kernel modules: ```````````````````````````````` For miniroots of Slackware 14.0 or older, you also may wish to wipe the kernel modules and kernels from the file system as it's unlikely that the kernel packages inside the miniroot are suitable for your Hardware Model. The following assumes that you are already inside the directory into which you have extracted the miniroot. DO NOT DO THIS OUTSIDE OF THE MINIROOT EXTRACTION DIRECTORY as you will break your system! # cd var/log/packages # ROOT=/tmp/armminirootfs removepkg kernel* Install the appropriate kernel, kernel modules and firmware ``````````````````````````````````````````````````````````` The miniroot file system archives are presented for users whose Hardware Models are not supported officially by Slackware, or on which the regular Slackware installer cannot be used. Therefore you will need to install a kernel, modules and possibly firmware into the miniroot before you can boot your new system. This differs on a case by case basis, and is outside of the scope of this document, but bares mentioning. From here you can make any other changes necessary and then use rsync -Pav (or cp -fa) to sync the data to your target Hardware Model. In the case of images for writing to NAND et al, you will need to create an image using particular programs for filesystems such as ubifs, j2ffs and so on. As I said, these root filesystems are for developers or competend Linux users; but if you find any methods to improve the initial rootfs images or can update these instructions to offer more options, please drop me an email. -- Stuart Winter 4th Feb 2010