-
Notifications
You must be signed in to change notification settings - Fork 0
Setup Linux Image
At this time the operating system of LEAP needs to be installed and configured manually. This guide describes the steps taken to get the Raspberry Pi OS in working condition before we can install and install and use the LEAP application.
Provision SD card with Raspberry Pi Imager
- Install Raspberry Pi Imager on your computer, following the installation instructions found here.
- Insert the SD card to your computer
- Open Raspberry Pi Imager.
- Select
Raspberry Pi 4when asked for the target device. - Select
Raspberry Pi OS (other)and thenRaspberry Pi OS Lite (64-bit)when asked for the operating system. - Select the SD card when asked for the target storage drive.
- Insert
leapas the system hostname. - Insert the corresponding localization settings.
- Use the
t4equsername andt4eqpassword. - (optional) Configure the WiFi SSID and Password.
- Activate SSH using password authentication.
- Write the image to the SD card.
After first boot you can SSH into the target computer using ssh t4eq@leap.local if your computer is connected to the same network as the Raspberry Pi.
The (Intenso) USB drive that is connected to the Raspberry Pi suffers from some issues when working in USB Attached SCSI mode, which lead to it eventually hanging during reads/writes. To avoid this issue, we can tell the Linux kernel to handle the quirks known for this USB devices (identified by the VID and PID).
Append the following characters to the /boot/firmware/cmdline.txt in the Raspberry Pi. Make sure that only one line is present in the file.
usb-storage.quirks=152d:0579:u
Now let's partition the USB drive. In almost all likelihood the drive will be present as /dev/sda, but you can double check with commands such as sudo fdisk -l, lsblk or looking at dmesg output. The remainder of this guide assumes that the drive is present at /dev/sda.
We can partition the drive with:
$ sudo fdisk /dev/sda <<EOF
g
n
1
w
EOF The drive should look like:
$ sudo fdisk -l /dev/sda
Disk /dev/sda: 238.47 GiB, 256060514304 bytes, 500118192 sectors
Disk model: Portable SSD
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 73BB8456-0F0B-4656-89E7-991BD1CCE409
Device Start End Sectors Size Type
/dev/sda1 2048 500117503 500115456 238.5G Linux filesystem
Now let's create a file system inside the one partition we created. We label it LEAP_DATA to be able to refer to it later.
sudo mkfs.ext4 -L LEAP_DATA /dev/sda1At this point, we just need to make sure that it gets mounted automatically on boot with:
$ sudo -i
# mkdir -p /var/lib/leap/
# echo "LABEL=LEAP_DATA /var/lib/leap/ ext4 defaults,noatime,nofail 0 2" >> /etc/fstab
# chown -R t4eq /var/lib/leap
# exitCheck that the filesystem gets mounted:
$ sudo systemctl daemon-reload
$ sudo mount -a
$ sudo mount | grep sda1
/dev/sda1 on /var/lib/leap type ext4 (rw,noatime)The system is finally ready to execute the LEAP software.