My thoughts on Slackware, life and everything

Tag: overlayfs

Beta 6 for my Live ISO images

blueSW-64pxYesterday  I uploaded new ISO images for Slackware Live Edition, release “0.6.0“. Then I waited a bit before writing this article to allow the mirrors to catch up with the 8 GB of new files.

Check out my previous articles about Slackware Live Edition for more background information and read the README.txt file provided with the “liveslak” sources to get a grasp on a more technical level of how this all works.

What’s new in 0.6.0?

Still working towards a stable 1.0 release, I think I am mostly there feature-wise and I would like to see bug reports so that I can be sure that a future stable release is going to be enjoyed by everyone – seasoned or aspiring Slackware user alike. If I am not at version 1.0 by the time Slackware 14.2 is released, that event will trigger a Live Edition v1.0 for sure! But we’ll get there before Pat 🙂

The persistent USB variant of Slackware Live is what most people are probably going to use. But the ISO on DVD or a read-only stick is just as awesome, because that variant will be particularly interesting for people who are demo-ing Slackware (because they are new to Slackware or because they want to see how slackware-current performs). For this new beta, I have focused on fixing all the small bugs I ran into, but here are some of the highlights in terms of new functionality:

  • You can now use an encrypted container file to store persistent data. The “iso2usb.sh” script was extended with a new “-C” parameter that allows you to specify a size for this LUKS container file, quite similar to what you already could do for a LUKS encrypted homedirectory. The data on your persistent USB Live will be safe from people who steal the stick from you.
  • A hard disk installer was added to all Live variants except the minimal XFCE. As far as I am concerned, the XFCE version is nice to run as a small Live OS but unsuited for hard disk installation. This works straight from the DVD, and also in USB versions.
    You will be able to install the latest Slackware64-current, or the Plasma5 or Mate version to your computer’s hard drive, in the background while you are working/playing in your Live Desktop.
    From within the Live environment (either at the console or in an X terminal in your running Desktop Environment) you can call “setup2hd” which will guide you. The script is a modified Slackware setup as known from the official install media, but it has already made the choice of package SOURCE for you. Note that you are responsible for partitioning your hard drive before you call “setup2hd”. This aspect is no different from the regular Slackware installer.
    The “setup2hd” script will install all the active Live modules to your hard drive (this encompasses all “system” modules, and furthermore including modules in addons/” and “optional/” which you enabled).
  • Documentation was added. A README.txt file contains all the details of using the Live Edition, as well as technical background on how the liveslak scripts do their work.
  • Customizing the Live Edition has been made easier. You are no longer tied to the choice of “SLACKWARE”, “PLASMA5”, “KDE4”, “XFCE”, “MATE” or “CINNAMON” when generating a new ISO variant. A “custom” variant with its own custom name and custom post-install configuration is now also possible.

Download the ISO images

I have created ISO images for the SLACKWARE, XFCE, PLASMA5 and MATE flavours using the latest Slackware64-current packages available (Tue Feb 23 19:31:59 UTC 2016) as well as latest Plasma 5 and Mate releases.

You can find the ISO images plus their MD5 checksum and GPG signature at any of the following locations – look in the “0.6.0” subdirectory for ISOs based on the liveslak-0.6.0 scripts. I made a symlink called “latest” which will always point to the latest set of ISO images:

These mirror servers should have synchronized by now.

The ISOs have two user accounts: root (with password ‘root’) and live (with password ‘live’). My advice: login as user live and use “su” or “sudo” to get root access (note: “su” and “sudo” will want the live password!).

The ISOs are able to boot both on BIOS-based computers (where syslinux takes care of the boot menu) and UEFI systems (where grub builds the boot menu, which looks quite similar to the syslinux menu):

slackwarelive-0.4.0_syslinux

Have fun! Eric

Slackware Live Edition – on its way to 1.0?

blueSW-64pxLast week the second Beta of the upcoming Slackware 14.2 was released. My goal was to have a new Beta of my liveslak ready by that time, so that I could provide new ISO images to test the Slackware Beta2 on a live medium. Unfortunately, there was an attack of the flu in my team at work and things got a bit busier than usual. There was a plus side to this: some last moment bug fixes which could be applied to my scripts – the result of having more evenings available to test. Therefore the new release is not labeled “0.5.0” but “0.5.1

Check out my previous articles about Beta1 Beta2 Beta3 and Beta4 releases for these scripts, they contain a lot of background about the reasons for creating “yet another” Live version of Slackware. The articles contain instructions on the use of the Live ISO images and their boot parameters and I am not going to repeat all of them here.

What’s new in 0.5.1?

My releases are meant to accomplish something I think is essential to my Live Edition. When I reach 1.0 it means that no essential functionality is missing, and that the features I am going to add later on are “nice to have”. I think that that liveslak is mostly complete at this point, but it is lacking proper documentation – the last thing to do before 1.0.

One of the essential properties of the USB variant of a Live Distribution is that it should be able to store your changes and make them persistent across reboots. In the 0.4.0 release, I added a LUKS encrypted homedirectory and earlier on, I implemented OS persistence by writing changes to a directory “persistence” in the root of the Linux partition of the Live USB drive. Some people will rather want to be able to use a FAT/NTFS formatted USB stick because that allows them easier data transfers to and from non-Linux computers. So my Beta5 adds an alternative persistence method: writing the changes to a loop-mounted container file instead. That file is called “persistence.img” and should be in the root of the Live partition. The “iso2usb.sh” script takes care of creating the persistence and LUKS container files, the process of transforming the ISO into a practical USB Live OS is straight-forward and simple.

Adding my Slackware Live Edition to a FAT formatted drive is an exercise I will leave to the reader, but in theory this should now be possible.

Some more noteworthy updates in 0.5.0:

  • The Compose Key for german keyboards is now Scroll Lock instead of Right-Alt (aka Alt-Gr).
  • A “toram” boot parameter allows you to run the Live OS completely in RAM (you can remove the bootable Live medium after boot).
  • A “blacklist” parameter allows you to blacklist kernel module(s) that prevent a properly functioning environment (like “nouveau” does with some new hardware).
  • The XDM graphical login for the XFCE variant was extended with a “console” button which allows you to effortlessly drop to a console (runlevel 3).

Download the ISO images

I have created ISO images for the SLACKWARE, XFCE, PLASMA5 and MATE flavours using the latest Slackware64-current packages available today (Slackware 14.2 Beta 2).

You can find the ISO images plus their MD5 checksum and GPG signature at any of the following locations – look in the “0.5.1” subdirectory for ISOs based on the liveslak-0.5.1 scripts:

Please allow some time to synchronize these mirror servers.

The ISOs have two user accounts: root (with password ‘root’) and live (with password ‘live’). My advice: login as user live and use “su” or “sudo” to get root access (note: “su” and “sudo” will want the live password!).

The ISOs are able to boot both on BIOS-based computers (where syslinux takes care of the boot menu) and UEFI systems (where grub builds the boot menu, which looks quite similar to the syslinux menu):

slackwarelive-0.4.0_syslinux

 

How to create a persistent USB stick from the ISO?

The ISO can be burnt to a DVD or copied to USB stick using ‘dd’ or just plain ‘cp’, but that will give you a read-only medium because all changes to the Live OS are in fact written to your computer’s RAM.

Use the ‘iso2usb.sh‘ script to create a Live OS on the USB device with persistence.

By default, the changes you make while running Slackware Live will then be preserved across reboots because the OS will write all these changes to the directory “persistence” in the root of the USB device. The script requires an input and an output parameter at a minimum:

# ./iso2usb.sh -i ~/Download/slackware64-live-current.iso -o /dev/sdX

… where /dev/sdX is the device name of your USB stick.

Alternatively you can use a file “persistence.img” in the root of the USB device which will be loop-mounted by the Live OS and changes to the system will be written to the filesystem inside this container file. A feature which should be appreciated by people who want to use a USB stick with a VFAT partition instead of a Linux ext4 partition. The script requires an additional parameter “-P” in this case:

# ./iso2usb.sh -P -i ~/Download/slackware64-live-current.iso -o /dev/sdX

 

Note that your USB stick will get formatted – erasing all data currently stored on it. The iso2usb.sh script will pause to show you the characteristics of the target device and ask you once more if you really want to continue erasing it. You will not easily destroy your hard drive unless you are really not paying attention!

How to create the LUKS encrypted homedirectory container?

The iso2usb.sh script has a parameter “-c” which takes a size argument. If you want to create a 400 MB container file to hide your homedirectory in, then you need to specify “-c 400M”. If you want 2.5 GB for your homedirectory, use “-c 2.5G”. If you are not concerned so much with the exact size but want to allocate a percentage of the free space on the stick, then use “-c 40%” to create a LUKS container that uses 40% of the available free space.

Now to put that into an actual example command line which will create a file (its name will be “slhome.img” starting with the 0.5.0 release) using up 50% of the free space on the stick:

# ./iso2usb.sh -i slackware64-live-xfce-current.iso -o /dev/sdX -c 50%

When the script gets to the point where it creates the LUKS container file, it will prompt you for a passphrase which will be used for encrypting and decrypting the container’s data. Right after that, the script will prompt you to enter that passphrase again when the LUKS container is unlocked and the ISO’s /home content is copied into the container.

Booting the Live OS

When you boot Slackware Live on a BIOS computer, Syslinux will handle the boot and show the following menu:

  • Start (SLACKWARE | PLASMA5 | XFCE | MATE) Live (depending on which of the ISOs you boot)
  • Non-US Keyboard selection
  • Non-US Language selection
  • Memory test with memtest86+

You can select a keyboard mapping that matches your computer’s. And/or boot Slackware in another language than US English. You will probably want to change the timezone; syslinux allows you to edit the boot commandline by pressing <TAB> because the syslinux bootmenu does not offer you a selection of timezones.

On UEFI computers, GRUB2 handles the boot and it will show a menu similar (and similarly themed) as the Syslinux menu:

  • Start (SLACKWARE | PLASMA5 | XFCE | MATE) Live (depending on which of the ISOs you boot)
  • Non-US Keyboard selection
  • Non-US Language selection
  • Non-US Timezone selection
  • Memory test with memtest86+

Editing a Grub menu is possible by pressing the ‘e’ key. After making your changes to the boot commandline, press <F10> to boot.

Another difference between Syslinux and Grub menus: in Grub you select keyboard, language and/or timezone and you’ll return to the main menu every time. You still have to select “Start Slackware Live” to boot. In the Syslinux menu, only the keyboard selection menu will return you to (apparently bot not actually) the same main menu. The non-US language selection will boot you into Slackware Live immediately without returning to the main menu. A limitation of syslinux.

Have fun! Eric

© 2024 Alien Pastures

Theme by Anders NorenUp ↑