Page 1 of 1

Some booting mechanisms

Posted: Fri Jun 10, 2022 6:45 am
by wiak

I'm currently revisiting booting mechanisms to help me streamline my own dev work needs. I will not be actually trying/using all of the following methodologies/mechanisms, but will have them on ‘my radar’. Note that I do not guarantee the URLs below are always the most recent (particularly for Puppy-related creations, which end up all over the place in the forum for some reason):

It is worth understanding a little about why they are not the same (or even for the same technical purpose despite all being part of some boot mechanism or other): viewtopic.php?p=26885#p26885

1. This first type of app does a few things. First, it can download a distro's iso (I think). Second, it installs the distro files via extraction from the iso. The result is effectively a frugal install, but may have a different different directory/file hierarchy structure in the frugal install folder than what Puppy users might be typically used to. I am thus not very fond of it personally. Third, it installs a bootable ‘bootloader/boot manager’ (i.e. installing some sort of grub or similar to the boot media, hard disk or more usually USB stick, as that first process). :
UNetbootin: https://unetbootin.github.io/
https://github.com/unetbootin/unetbooti ... howitworks

2. This second type of app simply takes an iso file or img file and writes the raw bits to the boot media. For that to work requires that the iso or img has been specially contructed to include a bootable boot manager such as via isolinux, or some sort of grub or similar. The problem with this method is that it simply overwrites the media of the usb stick (or whateveer) bit by bit, using the file system type (e.g. iso) of the installation media itself, so may or may not be read-only thereafter and not partitioned, so even if the img is small the rest of the usb stick space remains unaccessible thereafter (depending on how the installation media was originally constructed. Without checking them all, I believe the following fit into this category:
2a. USBImager: https://bztsrc.gitlab.io/usbimager/
2b. Balena Etcher: https://www.balena.io/etcher/
2c. Rufus (run from MS Windows): https://rufus.ie/en/
2d. dd (simple, more than somewhat dangerous default-provided Linux utility, though I use this a lot since has versatile options)
2e. EasyDD (simple GUI for dd): https://bkhome.org/linux/easydd-write-i ... drive.html

3. A third approach, which is an alternative to the above mechanisms is to boot from isos (or img files) themselves via the likes of grub2 iso booting methods, including direct grub.cfg iso-boot configuration, or the specially arranged SGD2 and Ventoy methodologies, or (unchecked by me) ISObooter(?):
https://www.supergrubdisk.org/
https://www.ventoy.net/en/index.html
https://oldforum.puppylinux.com/viewtop ... 50#p517250

The last two approaches (thus far), 4 and 5 below, involve splitting the boot procedure into stages: a. the utility used (e.g. pupit.sh or weedogit.sh) optionally downloads desired distro img, iso, or tar.gz for extraction; and 2. creates a frugal install via sfs files and so on, and usually in own subdirectory such that various frugal installations can optionally lie beside each other on same partition if so desired. It is left entirely up to the user to separately install a boot manager (such as grub), or use existing installed one:

4. This fourth approach requires a boot device that is pre-installed with the likes of grub2 or grub4dos, syslinux, or similar. Something like Pup's FrugalPup utility (viewtopic.php?p=1588#p1588) or Grub2config (viewtopic.php?p=29703#p29703) can be used for that, or any major distro pre-installed grub system (e.g. after a full-install, dual-boot with Windows or otherwise, of say ubuntu).
This fourth approach uses the original initrd provided by the distro itself and the app or script involved simply needs to extract/uncompresss the whole download media contents (e.g. iso or img or tar.XX) into typical frugal self-contained directory, which provides filesystem layer support (usually via aufs for traditional Pups) for flexible usage and save persistence facilities. That is pretty much all the shell script pupit.sh does: viewtopic.php?p=50074#p50074

5. A fifth approach, which is similar but more complex to approach 4, is that used by weedogit.sh. This WeeDogIT method also requires a boot device that is pre-installed with the likes of grub2 or grub4dos, syslinux, or similar. Again, something like Pup's frugalinstall utility or Grub2config can be used for that, or any major distro pre-installed grub system. The difference is that the WeeDogIT does not use the initrd of the original distro (since that may not provide flexible frugal install capability). Instead, weedogit.sh analyses and extracts only the core files needed for typical frugal self-contained directory from downloaded media contents (e.g. iso or img or tar.XX). It then manipulates these to allow the involved distro to be booted with WeeDogLinux generic initrd to provide overlayfs frugal installed flexible usage and save peresistence facilities: viewtopic.php?p=50074#p50074

No doubt there are other approaches, but the above are all used, or have been used by myself.

NOTE: You might also be interested in the thread, “USB installer programs 0ther OS's use to install Puppy to USB":
viewtopic.php?t=157