Alternatives to Debian Live for persistent Debian system on USB
Solution 1
I eventually used the live-build
tools in Debian itself to build a custom image on a separate Debian system. I discovered that using the hdd
option to build a binary that consists of separate files (as opposed to an ISO image), and then copying that to the pen drive and setting up Grub legacy on the pen drive, works perfectly. A separate kludge is necessary to boot on UEFI systems. That's what I'm using now.
Solution 2
Alternatives to Debian Live for persistent Debian system on USB
You can create a debian Live USB with persistence using the mkusb
tool :
How to install mkusb in Debian
These methods are tested in Debian Wheezy. It contains an instruction to install the ppa 'manually'. There is also an alternative to download the file(s) and check the download manually.
The mkusb
is tested and work fine on debian jessie and debian Stretch. There is no dependencies problem.
To install mkusb
, add the following line to your /etc/apt/sources.list
deb http://ppa.launchpad.net/mkusb/ppa/ubuntu xenial main
Import the gpg key :
apt-key adv --keyserver keyserver.ubuntu.com --recv 54B8C8AC
Update and install mkusb
:
apt-get update
apt-get install mkusb
The command line tool is mkusb-nox
(txt mode) , the GUI is mkusb
.
The are a few steps to create a Debian Live Persistent USB using the mkusb
GUI :
Download the Debian Live ISO from the official website.
Run mkusb
from the terminal. Choose d
option then validate:
d: dus , guidus, mkusb-dus - New, easy to use
- Choose : Install (make a boot device)
- Choose
p
: 'Persistent live' only Debian and Ubuntu - Select your debian.iso file and validate
- Select your USB device
- Select
upefi
: usb-pack-efi (default grub from ISO file) then validate - Choose the percentage reserved to your persistent partition then validate
- Select GO and validate (Yes , i want to go ahead), your USB will be formatted and partitioned
The 5 partitions :
partition 1 - ntfs 'usbdata'
partition 2 - bios_grub
partition 3 - fat32 boot,efi
partition 4 - iso9660 - cloned system
partition 5 - ext4 - 'casper-rw'
You can reboot into your Persistent USB when you receive the following message :
Done :-)
The target device is ready to use.
Solution 3
I have not tried that on a live session with persistence but it should not be any different than a regular install.
The live CDs are quite limited but you can add another flavor if you want. Removing one would be a bugger.
There is the "standard" live CD. This is not truly live. It installs the basic Debian desktop stuff and offers the usual DEs as tasksel options. You could pop it on a stick and then try finishing the install from there at tty console.
I have never tried that but see no reason why it wouldn't work. Sounds interesting enough that I may just have to do that.
Solution 4
You can use the current Debian LiveCD, the one with non-free, which I recommend so you have the firmware for what ever you plug into, or the regular one without.
Would recommend a 8G stick.
dd image to stick.
Add a partition after the image leaving a bit of breathing room for the image (a few MB).
Label that partition; persistence
In that persistence partition you need a; persistence.conf
file which has; / union
for minimum content.
I suggest adding /home
Only problem with this is that you will have to, each time you boot, edit the menu entry to include the word; persistence
in the instruction string. Hit enter and you should be all set.
There are ways to edit the ISO menu entries to avoid that menu entry edit but that is not within the scope of this question. Widget
Related videos on Youtube
ShankarG
Updated on September 18, 2022Comments
-
ShankarG over 1 year
For the last six years, my main workstation has consisted of a pen drive running the Debian Live images with a persistent partition. The images were simple, brilliant and reliable, and the online web builder for images was perfect for my use.
Recently I was looking to update my core system and discovered that Debian Live has undergone an "abrupt end." Both that article and other mails mention alternatives; some imply that
live.debian.net
is still active, but it just redirects to the main Debian wiki, which in turn only refers to the official CD images. Another article mentions thatvmdebootstrap
is being updated to be the replacement forlive-build
and other Debian Live tools, but I can't find any useful documentation on that either. And no one seems to be running a web image builder any more.Can someone point me to alternatives? In an ideal world, there would be some straightforward workflow to produce custom images similar to those that Debian Live used to make possible, and with the kernel options that it supported (some of which are very useful in a persistent USB situation). Is that possible in Debian any more? Can someone point me to a sequence of steps for that?
-
the_velour_fog about 8 yearsHave you tried Ubuntu? - I have operated for the last 2 months off of a live CD - in a way that sounds similar to how you used debian live. One reason I chose Ubuntu over debian live USB is that I could install packages on ubuntu live USB, but not on debian.
-
ShankarG about 8 yearsI did try Ubuntu a long time ago, but it had glitches when running off my USB drive. Could try it again but would prefer to stick with Debian if possible. I'm not sure why you couldn't install packages - I can, and my system operates in a way that's almost identical to a normal desktop (even packages in the downloaded image can be updated by installing them in the persistent partition; only the kernel and some others can't be updated).
-
the_velour_fog about 8 yearsIm not sure, but I suspect I couldn't install packages because I dont use persistance. I want everything to reset the next time I boot from live USB and I simply use
dd
to create my simple non-persistant live USB's. -
ShankarG about 8 yearsOk, that's a very different use case than mine. I have persistence enabled and use my pen drive as if it is a normal system.
-
Fiksdal about 8 yearsI asked the same thing in Software Recommendations SE. Someone in the comments recommended Knoppix. See more here: softwarerecs.stackexchange.com/q/31325/21581
-
ivanivan over 6 yearsDebian/Mint/Ubuntu all run fine off a USB drive, installed directly there with the bootloader installed to the USB disk (not the MBR, and not a partition). Only thing to watch out for is installing nvidia drivers or similar - it may make working on a machine with different hw a pain (ie, X may have an issue starting until reconfigured)
-
-
ShankarG about 8 yearsThanks. But the normal live CDs seem to be available in quite limited flavours. And will they accept the live-config kernel options?
-
ShankarG about 8 yearsHow would I "add" another flavour? That's where the web custom image builder was so good...
-
ShankarG about 8 yearsThe problem I see with doing a normal install on a USB stick is that live-config does a lot of hardware auto detection. If I installed normally on a stick, wouldn't it only work on the computer where I set it up?