Results 1 to 3 of 3

Thread: Remastering Knoppix7+: New uses of old overlay techniques

  1. #1
    Senior Member registered user
    Join Date
    Sep 2006
    Posts
    802

    Remastering Knoppix7+: New uses of old overlay techniques

    The 4GB file size limit of FAT32 has been an important premise for KNOPPIX (and similar live distros) in the past, and it still is the main reason why contemporary KNOPPIX comes with two cloop-compressed files: The basic KNOPPIX, and the overlay KNOPPIX1. Both sized to fit on a FAT32 file system.
    When we remaster, we can easily put everything into one file, but it has gotten increasingly harder to purge enough from the DVD package list to make everything fit within 4GB, when own additions are included.

    Experimenting a bit with 7.7.1 DVD remastering, it turns out that while it is fairly easy to purge enough to compress the DVD content into 4GB without any overlay, it is probably not worth it to shoehorn significant added packages into that format.

    And still, there are some good reasons to conform to FAT32. The most important is booting. While it is easy to prepare FAT32 media to boot almost everywhere, too often other kinds of media fail to boot somewhere. So for me, it's not worth the effort to do things otherwise. Also, this seems like an easy basis for running in Vmware Workstation virtual machines.

    This takes us back to the good old multiple overlays technique, which our friend utu has championed on this forum:
    http://knoppix.net/forum/threads/306...x-7-2-LiveUSBs

    The principle is that the persistent store is cloop-compressed into an overlay as KNOPPIX<n>, n=1,2,3..., put into the KNOPPIX directory and automatically aufs-mounted upon next boot. This isn't something I would recommend to do several times. There is, for example, no file deletion involved, old versions of files are not overwritten, but just superseded by newer versions in the aufs mount. In order to have "real" file deletion, remastering is needed.

    But it is possible to make Knoppix into a real power package this way. For example, running on ext3 one could make a 8GB overlay file containing lots of programs, like databases, statistical packages etc. Then compress it into a KNOPPIX1 ca 4GB overlay (assume we have purged and compressed the DVD contents into 4GB KNOPPIX), create 2-4 knoppix-data.img<n> overlay files in addition to knoppix-data.img and stuff everything into a 32 GB USB stick which can be booted "almost everywhere". For my own use, I'm quite sure it will suffice with a ca 2GB overlay. There is, for example, little to be gained by compressing JAVA .jar/.war files, as they are mostly already compressed.

    Here is the overlay creation function utu posted:
    Code:
    #utu's overlay creation
    #http://knoppix.net/forum/threads/30672-Using-Overlay-Updates-in-Knoppix-7-2-LiveUSBs
    
    MakeOverlay() { # Cloop-compress & save /KNOPPIX-DATA as /mnt-system/KNOPPIX$1
        ISO=KNOPPIX$1; ISODIR=/mnt-system/; ISOSRC=KNOPPIX-DATA
        echo -e "Creating "$ISO"; patience, this may take some time..."
        cd /; sudo mkisofs -x *[Cc]ache* -R -U \
               $ISOSRC | create_compressed_fs -B 131072 -m - - > $ISODIR$ISO
        echo ".done; "$ISO" additions from $ISOSRC saved to "$ISODIR"."
    }

  2. #2
    Senior Member registered user
    Join Date
    May 2006
    Location
    Columbia, Maryland USA
    Posts
    1,631
    .
    Nice to hear from you again, Capricorny.
    Thanks for the nice mention. A few notes come to mind on this topic:

    1. I still use this technique on a Knoppix 7.7.1 LiveUSB.

    2. In my case, I usually try to bundle all my own usual tweaks in a single
    first additional compressed overlay and then try to operate with a new modest
    reiserfs read/write persistence file. The compressed overlay is read-only and
    virtually immune to being written-over. The net contents of a new read/write
    persistence file is usually relatively small and it's therefore easy to erase
    (re-format) and to restore its contents from notes or (my own) memory if it
    inadvertently gets written-over and Knoppix operation is obviously corrupted.

    3. I'm sure this same idea will work to some degree with other Linuxes, such
    as Xubuntu, with minor adaptations such as adding a persistence partition and
    replacing cloops with squash files. This provides an avenue to starting with
    a much smaller compressed core Linux file than that of Knoppix's DVD editions.

    4. In addition-to or instead-of "utu's overlay creation",
    the quoted function definition, MakeOverlay, appearing by itself, should include
    the notices: "Copyright TJ Hoye 2013, License GPL Version 2".
    The script is my interpretation of the content of a debian-knoppix mailing list
    post by Klaus K describing how he prepares Knoppix images to include material
    in addition to a working version of Knoppix LiveDVD for special occasions.
    The GPL License notification is typical of Knoppixes of a certain era.

  3. #3
    Senior Member registered user
    Join Date
    May 2006
    Location
    Columbia, Maryland USA
    Posts
    1,631

    Introducing snaps

    .
    In reference to my previous mention of adding squash files in Xubuntu
    in item 3 above...

    Canonical is introducing a new feature for adding programs to Linux systems
    called snaps. This feature brings into being a whole new infrastructure
    which is somewhat reminiscent of stacking compressed knoppix overlays.
    Snaps, in effect stacks squashed file systems representing useful program
    additions which bring their dependencies with them. By stacking, I mean
    combining filesystems by means of a union filesystem. This infrastructure
    includes a means of creating such snap packages, called spapcraft, and a
    concept of 'stores' for obtaining useful snap packages or for offering some
    packages you might create yourself for others to use.

    Canonical introduced this system into Ubuntu, Debian and many of the more
    popular Linux systems in 2016. It is contained in Xubuntu 16.10, for example.

    You can get a feel for snaps with the following video:
    https://www.youtube.com/watch?v=MCrT_AhCOYk

    If you are interested in learning more about snaps, you might begin with
    the following introduction and its references:
    https://tutorials.ubuntu.com/tutoria...c-snap-usage#0

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


IBM System X3650 M4 7915AC1 Server 2*Intel Xeon E5-2640 0 2.5GHz 8GB SEE NOTES  picture

IBM System X3650 M4 7915AC1 Server 2*Intel Xeon E5-2640 0 2.5GHz 8GB SEE NOTES

$135.89



IBM X3500 M3 Server 2x E5620 8-Core CPU 128GB RAM M5015 RAID 4TB 8TB 16TB HDD picture

IBM X3500 M3 Server 2x E5620 8-Core CPU 128GB RAM M5015 RAID 4TB 8TB 16TB HDD

$139.95



lot of 2 IBM Power S814 Model 8286-41A Server RAM **AS IS untested** picture

lot of 2 IBM Power S814 Model 8286-41A Server RAM **AS IS untested**

$750.00



IBM RS/6000 44P Model 270 Server 375 MHz.256MB 18GB 1.44 Floppy DDS3 Tape Drive picture

IBM RS/6000 44P Model 270 Server 375 MHz.256MB 18GB 1.44 Floppy DDS3 Tape Drive

$500.00



IBM X3650 M5 5462-AC1,2 X E5-2640V3 2.6GHZ 8C, 16 GB, DUAL 750W, 0HDD SERVER  picture

IBM X3650 M5 5462-AC1,2 X E5-2640V3 2.6GHZ 8C, 16 GB, DUAL 750W, 0HDD SERVER

$205.99



IBM eServer xSeries 226 6LFF 2*Xeon 2.8GHz 6GB RAM No HDD 2*514W PS Tower Server picture

IBM eServer xSeries 226 6LFF 2*Xeon 2.8GHz 6GB RAM No HDD 2*514W PS Tower Server

$159.99



IBM x3650M3 Server Dual x5690 6 Core 3.47GHZ 64 GB DDR3 2x 146GB SAS picture

IBM x3650M3 Server Dual x5690 6 Core 3.47GHZ 64 GB DDR3 2x 146GB SAS

$160.00



IBM x3650 M5 SFF 24 Bay 1x Xeon E5-2620v4 16GB RAM ServeRAID M5210 2x 900W picture

IBM x3650 M5 SFF 24 Bay 1x Xeon E5-2620v4 16GB RAM ServeRAID M5210 2x 900W

$168.85



IBM HS23 Server 2x Xeon E5-2630 @ 2.30 GHz NO HDD NO RAM NO OS (LS) picture

IBM HS23 Server 2x Xeon E5-2630 @ 2.30 GHz NO HDD NO RAM NO OS (LS)

$58.45



IBM SR2300 Intel Xeon 3.20Ghz 2GB Ram Server w/CDROM/2xPS Delta DPS 500EB picture

IBM SR2300 Intel Xeon 3.20Ghz 2GB Ram Server w/CDROM/2xPS Delta DPS 500EB

$124.99