Site Map - skip to main content

Hacker Public Radio

Your ideas, projects, opinions - podcasted.

New episodes every weekday Monday through Friday.
This page was generated by The HPR Robot at

hpr2672 :: Porteus

Installing Porteus and the cool things you can do with thumbdrive installation

<< First, < Previous, , Latest >>

Hosted by Klaatu on 2018-10-30 is flagged as Clean and is released under a CC-BY-SA license.
porteus, slax, installation, howto, tutorial, usbdrive, thumbdrive. 4.
The show is available on the Internet Archive at:

Listen in ogg, spx, or mp3 format. Play now:

Duration: 00:57:57


Porteus is a portable Live Linux distro, based on Slackware, intended for use on thumbdrives or optical media. It is, more or less, the new Slax, now that Slax has switched to Debian.


The official means of installation is to burn Porteus to disc, and then (optionally) install Porteus onto a thumbdrive from within Porteus. To install Porteus to a thumbdrive, you need a thumbdrive with an EXT4 partition. You can try other filesystems and partition schemes, but EXT4 definitely works well.

From either Porteus or Slackware (you can try other distros, but results will vary), you can do a manual install, and here are the correct commands (as of this writing, the docs on are not accurate). Assuming you have discovered, using lsblk, that your target device (the thumbdrive) is /dev/sdx:

$ sudo bash
# mkdir -p /mnt/loop /mnt/drive
# mount --options loop /path/to/Porteus*iso /mnt/loop
# mount /dev/sdx1 /mnt/drive
# rsync -av /mnt/loop/ /mnt/drive/
# cd /mnt/drive/boot
# chmod +x
# ./Porteus*com

Alternately, you can use Porteus from a virtual machine and install to a thumbdrive, as long as your virtualisation software redirects USB. I have used virt-manager running on Fedora successfully for this.

The other alternative, of course, is to run Porteus off of an optical disc. That means your system is unwritable, so nothing you do is persistent across reboots, but you can save your work to a thumbdrive. I've worked with Slax this way before, and it's quite manageable.


Booting to Porteus depends a lot on the firmware of the computer you're booting. Almost every Linux distro in existence has accurate docs on the changes you may or may not need to make to your BIOS or [U]EFI in order to boot to Linux, so you can find more detail on this if you need. Here's some text I borrowed from Linux Mint:

Insert your USB stick (or DVD) into the computer.

Restart the computer.

Before your computer boots your current operating system (Windows, Mac, Linux) you should see your BIOS or UEFI loading screen. Check the screen or your computer’s documentation to know which key to press and instruct your computer to boot on USB (or DVD). Most BIOS or UEFI have a special key you can press to select the boot device and all of them have a special key to enter a configuration screen (from which you can define the boot order). Depending on the firmware, these special keys can be Escape, F1, F2, F8, F10, F11, F12, or Delete. That information is usually briefly displayed on screen during the boot sequence.

On Macs, keep your finger pressed on the Alt or Option key after hearing the boot sound.

Boot modes

Porteus can boot to its default persistent modes: graphical or text. Both of these modes auto load any Porteus modules you've installed and also read any changes you made since the previous boot.

It can also boot to ephemeral modes: Copy to RAM and Always Fresh. These modes act as if you've never booted into Porteus before, loading a completely fresh version of the file system. They also do not load Porteus modules automatically.

Installing software

Porteus modules are Slackware packages converted to .xzm files, a highly-compressed SquashFS filesystem. When a Porteus module is activated, the application and other files contained in the module appear in your environment. You can think of it as a layered filesystem.

To install software, you must sync up your package manager with upstream repositories:

$ sudo usm -u all

Once everything is updated, you can search for packages using the -k (for keyword) option:

$ sudo usm -k foo

And then install it:

$ sudo usm -g foo

You are prompted to either install or download the module. If you install it, then it becomes part of the filesystem. However, since changes to the filesystem are NOT read by the Copy to RAM or Always Fresh modes, this is probably not what you want. Instead, download the module so that you can have Porteus load it dynamically regardless of what mode you're running.

Modules are downloaded, by default, to /tmp/usm/ and then converted from their native format of .t?z to .xzm files. You can copy the .xzm files to an external device if you're running off of optical media, or into a persistent area on the thumbdrive running Porteus. Modules can be made permanently available in the /mnt/sdx1/porteus/modules or /mnt/sdx1/porteus/optianal directories.

Modules in the ../modules path are loaded at boot in the Graphical and Text modes, and are available to load manually in the Copy to RAM and Always Fresh modes.

Modules in the ../optional path are never auto loaded.

Modules can be activated or deactivated with this command:

$ sudo activate foo


Flatpak works on Porteus, too. I have found this to be convenient for applications like GIMP and Inkscape and Kdenlive and many others that are complex enough to warrant special attention.

Flatpak does require the glib-networking package. You will not be warned about this, because all upstream Slackware repositories assume a full install of Slackware (and glib-networking is included on Slackware, but not on Porteus). Once you install glib-networking, you can use flatpak as described, for instance, on the GIMP downloads page.

Over-customizing the "hard-coded" parts of Porteus is unwise. For instance, keep the default user (guest), don't try to change the UID (I tried and failed), and so on. Treat the system, more or less, as if though you were a guest on someone else's multi-user system. Install and customise stuff locally and through modules when possible. That's what Porteus expects, and things can break if you try to treat it too much like a traditional Linux system.


Subscribe to the comments RSS feed.

Comment #1 posted on 2018-11-11 22:23:13 by Alison Chaiken

particularly informative episode

I've never made much use of 'live' media except for installation and system rescue, but I found the ideas shared by Klaatu particularly thought-provoking. I have been travelling and wanted to perform some simple task like airline check-in from a lobby computer but hesitated over using Windows of any flavor for anything. It would be fun to at least try to reboot these machines as Linux, but don't things like network proxy configuration screw up such attempts?

It would also be fun to test-drive Linux on PCs or laptops in computer stores, but don't staff wander by and tell the perpetrator to stop? And doesn't secure-boot stop such attempts anyway?

I'm curious therefore, Klaatu, on what kinds of systems has this approach been successful? Older, pre-secure-boot PCs?

Comment #2 posted on 2018-12-03 02:33:59 by Klaatu

Late response better than no response

Sorry, Alison, I only just saw your comment.

Network Proxy configs: I don't have trouble with it, but I also have a VPN available to me; maybe that gets around some wonky network setups. I have not had a problem in airports, universities, hotels, conference centers, or really anywhere that I can think of.

Test-drive Linux in store: I do this as a matter of habit. If I'm in a store with computers for sale, I usually reboot at least one PC to Linux just to keep tabs on what works out of the box these days. It seems rare for UEFI of display models to be locked down, so I open the UEFI UI, disable Secure Boot, reboot to Linux, test stuff, and then re-enable Secure Boot to avoid what would be vandalism (I have no interest in giving Linux geeks a bad name - "keep an eye on that one, he'll break our display models until corporate sends somebody to fix them")

I've only been approached/reprimanded once for doing this. I calmly explained that I was testing Linux, which I require for work, because I was considering a purchase. The salesperson did not stand down, so I calmly rebooted and later sent an email to the store manager telling them that Linux is a real OS that real people in the area use at work, so the sales team ought to be made aware of it. I haven't had a problem since in that store (Warehouse Stationary in NZ, for the record).

Otherwise, no one has ever bothered to approach me about it. I guess if I was nervous about it, I might try to find a sales person and explain what I needed to do, and why, and then ask if I may demonstrate the process, walking them through everything as I did it. Throwing fancy words around, like "programmer" and "software developer" and "C++" might help dazzl le them into submission.

Either way, it's worth a shot.

Comment #3 posted on 2019-02-26 06:37:56 by clacke

Re: Test-driving Linux in computer stores

Alison, I've been pleasantly surprised here in Hong Kong that if I ask the store clerks, they will generously allow me to boot from my USB stick to see how well Linux runs, no complaints whatsoever.

And that's lucky too, because last spring and summer when I was shopping for a new machine, I tried like ten of them before I found one where screen, Wi-Fi and touchpad were working without glitches and the machine didn't crash after a few minutes.

Comment #4 posted on 2021-11-02 09:59:28 by hhskladby

Porteus Modularity

Nice exposition, some things would need further / correct explanation also to klaatu (!), blame it on Porteus' not-so-well own documentation, now and here only this what is VERY important (though not Porteus specific): Porteus' XZM modules (as they are aufs / squashfs as in eg. Slax) do not "overwrite" anything on your machine, they interrupt your file system calls and make them believe that there are things that are not really there, so deactivating a module or restarting gives you an unchanged file system again, and if two programs conflict in shared resource file versions, you need not uninstall something, you just activate / deactivate modules - those modules may just be different versions of one library file, i.e. you can make a single file or a directory a module, and always your "initial" will not be corrupted by workarounds

Leave Comment

Note to Verbose Commenters
If you can't fit everything you want to say in the comment below then you really should record a response show instead.

Note to Spammers
All comments are moderated. All links are checked by humans. We strip out all html. Feel free to record a show about yourself, or your industry, or any other topic we may find interesting. We also check shows for spam :).

Provide feedback
Your Name/Handle:
Anti Spam Question: What does the letter P in HPR stand for?
Are you a spammer?
What is the HOST_ID for the host of this show?
What does HPR mean to you?