79 lines
3.9 KiB
Markdown
79 lines
3.9 KiB
Markdown
# Void Linux Setup for USB Sticks
|
||
|
||
```
|
||
_________________________
|
||
.*¯ _ _ __ ___ /|_______
|
||
/ | |//,·¯¯*. / // _ \ // // /|
|
||
| | '// ( ) ;/ // // / // _¯ ///
|
||
| |_/ '.__.*/_//___.* // // ///
|
||
\*·…_____________________/’–––––––://
|
||
*·…_____________________|;–––––––'*
|
||
```
|
||
|
||
This repository holds scripts for installing a Void Linux setup specialized to run off a USB stick.
|
||
|
||
This is only for USB sticks (thumb drives, pen drives, whatever you wanna call them).
|
||
You don’t need this if you want to use a USB HDD or SSD because these devices tend to just work properly.
|
||
If you want to use a USB HDD/SSD, simply download the installer for the Linux distro of your choice and
|
||
install it on that drive. Most modern distros know how to cope with external drives.
|
||
|
||
The reason this is useful for USB sticks is that most of them are a bit shit.
|
||
Trying to run an operating system off a USB drive typically results in a corrupted drive pretty quickly
|
||
(if you can get the system to install properly in the first place). The scripts and configuration files
|
||
in this repository are made to address this by keeping changes to the system in RAM until shutdown and
|
||
therefore lowering disk I/O.
|
||
|
||
## Installation
|
||
|
||
You need the following:
|
||
- Computer (duh)
|
||
- ???G of RAM or more
|
||
- Can boot off USB (most computers made after 2003)
|
||
- USB stick (at least ???G)
|
||
- Internet connection
|
||
- During the installation, roughly ??? will be downloaded.
|
||
|
||
There are a couple manual steps to get started before the installer scripts can take over:
|
||
- Set up a Void live medium
|
||
- Download here: https://voidlinux.org/download/
|
||
- The following instructions assume you downloaded the "base" image
|
||
- Burn to CD/DVD or flash it to USB stick
|
||
- Windows should have a built-in thing for burning ISOs to optical media.
|
||
- You can use something like Win32DiskImager or Rufus for USB sticks.
|
||
- This will delete what’s on the stick.
|
||
- Boot into Void live and prepare things
|
||
- Things I can’t help you with (sorry):
|
||
- How to boot off CD/USB depends on your computer, so you’ll have to find out elsewhere.
|
||
- Be aware that Void uses a US keymap until you change it. If your keyboard is different, you might need to look up an image of a US keyboard to find the right keys.
|
||
- If booting off the USB stick you want to install to, use (RAM) option
|
||
- Log in as `root`, password `voidlinux`
|
||
- If you need to use WiFi, run `void-installer`
|
||
- Set your keyboard layout (optional)
|
||
- Connect to your network
|
||
- Abort the installation (don’t touch anything else)
|
||
- Download and run stage 1 of the USB installation script
|
||
- The base image doesn’t come with a way to download files so you need to install that first: `xbps-install -S wget`
|
||
- If it yells at you about updating xbps, do that, then try again
|
||
- `wget https://lostcave.ddnss.de/git/BodgeMaster/void-minecraft-usb/raw/branch/master/install-stage1.sh`
|
||
- `bash install-stage1.sh`
|
||
|
||
The scripts will take it from there, asking you for information and downloading things as needed.
|
||
|
||
## How It Works
|
||
|
||
`//TODO:` Add detailed documentation of how the thing works, changes to the boot up process, and whatever other scripts are in here
|
||
|
||
## Files
|
||
|
||
- `install-stage1.sh`: sets up the base system and prepares for installation stage 2
|
||
- `install-stage2.sh`: continues setting up things after booting into the freshly installed base system
|
||
- `opt/`: contains files to be installed in /opt/void-usb/
|
||
- `grub-config`: custom grub config generator (probably not necessary but at this point I don’t wanna dig into the default one)
|
||
- `backup-fs`: helper script to rebuild the squashfs
|
||
- `kernel.d/`: kernel hooks to be installed in /etc/kernel.d
|
||
- `skel/`: files to be added to /etc/skel
|
||
- `bashrc`: my custom .bashrc
|
||
- `user-readme.txt`: will be displayed on first login
|
||
- `xinitrc`: what dis look like?
|
||
- `notes_to_self.txt`: will disappear once finished
|