Live USB, in computing, is a removable mass storage device (USB memory) that houses an operating system in its entirety and which is capable of starting a computer.
Starting from this concept the question is; Can you create a live USB from a GNU / Linux distribution? The answer is “YES”, in Debian GNU Linux There is even a set of advanced tools that allow you to create live USB / DVD / BR in a simplified way, this is of great help for those GNU / Linux users who want to take their system operating and most used applications in the enormous portability offered by a removable USB storage unit such as the “PEN DRIVES”.
In this post it will be shown how to create a live USB / DVD is a series of simple steps that can have versions adapted to your needs which can be executed on any computer that has a USB port or a DVD reader unit.
The first thing we must know is what software tools are available in Debian GNU / Linux in order to create a live USB / DVD. The name of this tool is “livehelper” which is made up of the following packages with software tools:
- live tools
- live configuration
- live construction
- live boot
- live manual
It should be noted that livehelper is the best tool that has been created within the debian project that allows simplifying the process of creating a live USB / DVD in a few steps, which, if you had to do everything manually, would be a very cumbersome job. and it could take many days.
In Debian GNU / Linux the installation is very simple, you just have to install the packages with software tools as super user (root) as follows:
apt-get install live-tools live-config live-build live-boot live-manual
The package manager will install everything you need plus its dependencies.
Starting the steps to start creating the live USB / DVD
1. The first thing to do before building the live USB / DVD is to create the directory to work and enter it, this would be the first step below the commands:
mkdir -p workdir && cd workdir
2. The next step is to understand the first command to preconfigure the future image of live USB / DVD to be created where configurations such as; processor architecture, bootable type, if it will include the operating system installation system, what repository areas will be included to build the image, hostname, username, bootloader among many other configurations:
For example, a live usb with amd64 architecture will be created, with installer, debian operating system version 10 code name (buster) with the following command (remember that to execute all the commands to build the live USB / DVD it is in super user or “root”):
lb config -a amd64 -d buster -b iso-hybrid -s hdd --debian-installer true --debian-installer-distribution buster --bootloader syslinux --archive-areas "main contrib non-free" --bootappend-live "locales = es_ES.UTF-8 keyboard-layouts=en boot=live config hostname=mycomputer username=user"
Executing the above command, this pre configures the working directory to start building the live USB / DVD but an extra configuration would still be missing.
3. The configuration is to specify software packages that include a graphical environment and applications that you want to use in the live unit, with the following command a plain text file will be created where you will have the list of packages that you want to install in the image from alive:
nano config /package-lists/packagelist.list.chroot
Inside the file that is being created in the previous command we can add the following packages (be careful, just write the package name and in the next line write the name of another package and so on all the packages that are required):
This list of packages specify the installation of the LXDE desktop environment and some basic tools the list of packages is usually longer if you want office applications, multimedia, programming, design among many others available within the immense availability of applications in the repositories of this GNU / Linux distribution.
4. Having the package with software tools specified in detail to build the live image bada in debian GNU / Linux 10 (buster), you just have to execute the following command:
lb build –f
This will take a considerable time since you will download a lot of software packages from the internet and do the process of building the live image and then copy it to a removable storage unit such as a pendrive (USB) or a DVD / BR.
Note: the resulting image will appear in the working directory, which will only need to be transferred to a pendrive (USB) using the following command:
dd if = systemlive.iso of = /dev/sdb
Where / dev / sdb represents the removable pendrive drive if the representative acronym of the removable drive (pendrive) is unknown, only the following command should be executed as super user (root):
Note 2: to record the image on a DVD / BR you will only have to use any of these graphic or terminal programs which can be mentioned; k3b, brasero or wodim, the latter we can execute the following command to burn the cd / dvd / br:
wodim -v dev = /dev/sr0 speed=8 -eject systemlive.iso
Apparently the Debian project is discussing eliminating these software tools and possibly in a new version of Debian they are not officially available, if you do not want them to be abandoned and continue their life cycle and you have programming knowledge, contact through IRC or Email Debian mentors and Debian devs and offer your help. You will be welcomed into the project and you will be able to help make these software tools better every day.
How to help financially?
On the official website of the Debian project you can find the donations section which you can make a donation through Paypal or bank transfer, you just have to inform yourself to know how you can help this will allow you to cover developer and infrastructure expenses within this excellent project, we must remember that the Free software projects are mostly non-profit organizations that make the effort to create free software, improve it and maintain it over time, so that it is not abandoned and later dis-used.