KL your full installed distro (can use either)

KL your full installed distro


Moderator: Forum moderators

Post Reply
User avatar
wiak
Posts: 4069
Joined: Tue Dec 03, 2019 6:10 am
Location: Packing - big job
Has thanked: 65 times
Been thanked: 1200 times
Contact:

KL your full installed distro (can use either)

Post by wiak »

EDIT: NOTE WELL: To avoid full install swapfile or similar issues, which will otherwise likely occur, please refer to the following workaround solution: viewtopic.php?p=116939#p116939

KL_full2frugal (KL_full2fr in short)

Embracing what some see as the 'Other' distros and making them part of KL; a new era and in that an attempt to broaden/widespread forum appeal: bringing in the 'Others' as part of the forum audience.

Scenario:

You have a full installed distro such as Linux Mint (I used XFCE) or Zorin, Manjaro or Endeavour or whatever (I've only tried it with Linux Mint XFCE and Zorin OS lite XFCE so far, but should work with many - only thing that might go wrong would be if script can't find the full install vmlinuz - just extract that manually if that proves to be a problem).
You love its power and ease of upgrade, but miss all the forum layered OS functionality (and particularly no persistence and/or save on demand modes and sfs addons).

Method:

Have you used previous weedogit? Well it's a similar process (albeit that very different scenario). Just involves running a single 'build script' (attached), but MUST be run from the running full installed OS (e.g. Linux Mint, Zorin or similar) and from inside an empty directory you create just off its / (top of) Filesystem directory. That is you run your (say) Linux Mint full installed OS and then:

Code: Select all

mkdir -p /KL_full2fr

Note that the name of the directory you make doesn't actually matter... but it must be at the very top of the full install hierarchy. EDIT:(i.e. a subdir of /)

Then, put the KL_full2fr.sh script in there (remove the dummy tar), and make it executable.

DISCLAIMER BEFORE PROCEEDING FURTHER: The usual caveats - use at your own risk. Also bear in mind this is a new project/approach and thus should be considered alpha-grade software that might do terrible things to your pre-installed system(s), but it works fine thus far for me. Bug reports welcome of course. Uses same initrd as in KLV-Airedale for now, but with special new external w_init that once tested enough will later likely make it into next FR initrd release

For brief but somewhat detailed instructions you can always first run script in terminal (from its containing directory) with command:

Code: Select all

./KL_full2fr.sh --help

ONCE YOU ARE READY... with terminal open at the scripts containing directory (within your running Linux Mint or similar full installed system and NOT from KLV or Puppy or DD or similar - you must run the script from the full installed big distro!!!)

THAT IS:

Installation instructions:

1. Boot your target mainstream full installed distro (e.g. Linux Mint)

2. In that running distro run command: sudo mkdir -p /KL_full2fr

3. Put KL_full2fr.sh script inside /KL_full2fr and from terminal opened as

root user inside that directory run script with command:

./KL_full2fr.sh (or: ./KL_full2fr.sh --help for this help text)

4. Wait patiently till script builds boot components and outputs grub2 stanza.

5. Still with root user permissions, append that grub2 stanza

to (end of) mainstream distro file: /etc/grud.d/40_custom

and run command: sudo update-grub

6. On reboot you should find that new grub2 menu entry to

optionally frugal boot your mainstream distro.

You can still instead boot your mainstream distro as

normal full installed distro whenever you so should wish.

Notes:

By default the KL_full2fr will boot with no persistence RAM0 mode.

If you wish to use save on demand RAM2 mode you will need to set

up grub2 to put upper_changes folder on a separate partition.

For further information read the produced /KL_full2fr/grub_config.txt

and, if wanting save-on-demand (FR RAM2 mode) also refer to: viewtopic.php?p=94370#p94370

Yep, that's all there is to it (basically). I hope it worked for you (on reboot). The underlying full install distro itself does not get written to when in KL frugal mode (actually, the 'Linux Mint' or whatever gets mounted read-only as one of the overlayfs layers) so can still be used in that original full-install form anytime.

NOTE: You should find that gtkdialog program is available... Open a terminal and enter: gtkdialog --version
Also, filemnt program is there, as is precord and wex, AND, save2flash for when you are booted into RAM2 save-on-demand mode. However, precord needs lame added from package manager as a dependency; wex needs giblib1 and ffmpeg and xterm or rxvt-unicode or similar. Don't try running precord or wex until you have added their dependencies (best would be to add the dependencies first to the underlying full installed Linux Mint or whatever).

Once you have it all going, the world is your oyster - just follow KLV or KLA developments and pretty much every utility/extra developed there can be added to your KL_full2fr distro. You can instead reboot back into your normal full install anytime you wish (KL_full2fr basically just provides you with an extra grub2 menu option - it doesn't write to the underlying full installation itself).

If you are interested in the overlay structure of your 'new' distro; once it is booted just look in directory /mnt/layers - all the addons are mounted to the subdirs in there so you can see their contents. gtkdialog is provided by 12KLgtkdialog sfs in subdir named simply with underscore character. All will be explained later.

Some forum posts I made a few days ago as an intro to the dev work I was doing for this explain how to set up and use RAM2 save on demand mode with this: viewtopic.php?p=94370#p94370
Needs upper_changes put in alternative to the boot partition via w_changes= and w_changes1=RAM2 grub2 kernel line stanza alterations. You could use an external usb stick for the upper_changes if you wish, or alternative partition on your hard drive (I used alternative partition on hard drive when I wanted RAM2 save on demand mode and put the upper_changes in a folder named 'sessions', but use what you like). Sorry for some repetition - I am short on time so wrote this in a hurry, but purposively leaving as is since good to have some matters emphasized.
Note the special new option in the grub2 stanza: w_bottom=full2fr; that is essential for this usage - it tells the FR initrd (external w_init part) to make the underlying full installed filesystem the bottom layer of the normal overlayfs stack.

Caveat/restrictions (only apply when using full2fr and not to normal KL distros):

Unlike normal KL-distros, you can only use sfs addons in same partition as the underlying full install (not uncompressed dir addons). However, you CAN also use uncompressed dir addons as long as you store these in different partition to the bootfrom partition (perhaps alongside upper_changes if using RAM2 mode for example).
You should be careful if using RAM2 upper_changes persistence if you add packages there, and then later add packages in full install boot mode; think about it... that would break the likes of apt database - be thoughtful about such matters; won't harm your full install since full2fr isn't writing to that, but you might end up having to start with new upper_changes folder if you mess up when using persistence in frugal boot. Or just use RAM0 no persistence mode (the default) for experimenting without persistence - that's the main advantage really anyway...

FYI

How many layers can you use? Answer is 199 (including reserved layer for 00modules). That is, 99 layers like current KLV-Airedale, but now with 99 layers (also numbered in order from 00 to 99 below that 00modules layer - i.e. underneath the full install filesystem hierarchy, which is inbetween these two regions in terms of where it is in the overlay. Of course, you can't really probably use 199 layers because the system won't allow that many mounts I guess, but plenty of scope and I have managed total of 100 layers in experiments in the past...
By default, mainstream distros boot to a 'normal user' desktop. But it is easy to alter them to boot to root desktop if you really want that - I don't usually bother because nowadays so many apps don't like running as normal user and other problems waste more time than I find them worth.

Good Luck in your trial.

wiak

Remove fake .tar from the name and make it executable.
Fake .tar added to name so file could be attached.

Attachments
KL_full2fr.sh.tar
use on running full installed distro
(6.93 KiB) Downloaded 109 times
Last edited by bigpup on Wed Jul 26, 2023 2:24 pm, edited 1 time in total.

https://www.tinylinux.info/
DOWNLOAD wd_multi for hundreds of 'distros' at your fingertips: viewtopic.php?p=99154#p99154
Αξίζει να μεταφραστεί;

User avatar
wiak
Posts: 4069
Joined: Tue Dec 03, 2019 6:10 am
Location: Packing - big job
Has thanked: 65 times
Been thanked: 1200 times
Contact:

Re: KL your full installed distro (can use either)

Post by wiak »

So... Having finally become impatient waiting for Zorin to move on from a Focalfossa base to Jammy, and thus installed Linux Mint XFCE a few days ago, I just noticed that Zorin has now at last released a new version based on Jammy... sigh. My partner now wanting Zorin back... ::cry::
Apparently Zorin has a new updater script so at least on this one machine I'm on just now, if that works, I still have previous Zorin lite and can try updating that to save testing time. EDIT: Oops... upgrade script only for those who have paid version. Oh well, fair enough. I'll install Zorin lite OS from scratch maybe (tried to download iso, but download crawling here - perhaps cos new release and many want to try it...).

Oh well, I'm curious to try new Zorin release anyway, to see if anything lost in the free version of if generally improved, and also to make sure KL_full2fr works with it as I believe it should. Thereafter I'll check most of the other popular Linux distros to see if KL_full2fr likely to work with them without any changes needed. On the whole that is just a matter of seeing where they store their vmlinuz and what they name it - so I expect a high success rate without needing any script fixes. Do however please let me know if KL_full2fr works for you or not when and if you try it; otherwise my assumption is that it worked so nothing I need to fix thus far (my hope anyway, but whatever...).

https://www.tinylinux.info/
DOWNLOAD wd_multi for hundreds of 'distros' at your fingertips: viewtopic.php?p=99154#p99154
Αξίζει να μεταφραστεί;

User avatar
wiak
Posts: 4069
Joined: Tue Dec 03, 2019 6:10 am
Location: Packing - big job
Has thanked: 65 times
Been thanked: 1200 times
Contact:

Re: KL your full installed distro (can use either)

Post by wiak »

So I finally managed to download the new Zorin lite ver 16.3 XFCE iso and just finished installing it in parallel with the other distros I have installed on this machine: MS windows, Zorin lite ver 16.2, Linux Mint XFCE and various frugal installed KL distros and Pups.

Okay..., so now I've just downloaded KL_full2fr.sh.tar from forum (and removed the fake .tar extension and made it executable) into a directory I made that decided to name: /KLfull2fr_Zorin16_3 on the / (top of hierarchy) of my new full installed Zorin lite 16.3. I will now run that script prior to submitting this post and hopefully I will quickly (after adding the script-provided grub stanza to /etc/grub.d/40_config followed by sudo update-grub) then be ready to reboot into KL_full2fr version of Zorin lite 16.3 in FR initrd RAM0 no persistence mode. Here goes... (29Jul2023 01:17am...)

From terminal opened at KLfull2fr_Zorin16_3 running the script with command:

Code: Select all

./KL_full2fr.sh

and I chose option 2 from the provided menu... and waited for the script to complete and provide the grub2 menu stanza.

Actually, menu option 1 would also have worked since I the script code for option 2 choice is identical at the moment... I just made provision for alternative scripting behavior in case I need it later for some distro or other that needs different treatment.

https://www.tinylinux.info/
DOWNLOAD wd_multi for hundreds of 'distros' at your fingertips: viewtopic.php?p=99154#p99154
Αξίζει να μεταφραστεί;

User avatar
wiak
Posts: 4069
Joined: Tue Dec 03, 2019 6:10 am
Location: Packing - big job
Has thanked: 65 times
Been thanked: 1200 times
Contact:

Re: KL your full installed distro (can use either)

Post by wiak »

DONE... 01:18am. Time to reboot... back in a minute in the frugal version...

https://www.tinylinux.info/
DOWNLOAD wd_multi for hundreds of 'distros' at your fingertips: viewtopic.php?p=99154#p99154
Αξίζει να μεταφραστεί;

User avatar
wiak
Posts: 4069
Joined: Tue Dec 03, 2019 6:10 am
Location: Packing - big job
Has thanked: 65 times
Been thanked: 1200 times
Contact:

Re: KL your full installed distro (can use either)

Post by wiak »

And now booted into the KL frugal version of same new Zorin lite 16.3 at 01:20am... Working fine (RAM0 no persistence mode).

Attachments
KL_full2fr_newZorinScreenshot_2023-07-29_01-22-45.png
KL_full2fr_newZorinScreenshot_2023-07-29_01-22-45.png (103.58 KiB) Viewed 3169 times

https://www.tinylinux.info/
DOWNLOAD wd_multi for hundreds of 'distros' at your fingertips: viewtopic.php?p=99154#p99154
Αξίζει να μεταφραστεί;

User avatar
wiak
Posts: 4069
Joined: Tue Dec 03, 2019 6:10 am
Location: Packing - big job
Has thanked: 65 times
Been thanked: 1200 times
Contact:

Re: KL your full installed distro (can use either)

Post by wiak »

Well final test prior to bed. It's 01:36am...

I have created a folder /sessions in a different partition (UUID 424d8f42-e835-4111-9053-dd086b3d38e8) to the new Zorin full install

As root user in text editor, I just changed the /etc/grub.d/40_custom entry (w_changes part of the grub stanza)

from:

w_changes=RAM0

to

w_changes=UUID=424d8f42-e835-4111-9053-dd086b3d38e8=/sessions w_changes1=RAM2

and saved that.

I then needed to reboot into the full installed Zorin (since was in KL full2fr RAM0 mode at the time). Need to be in full install to do the necessary: sudo update-grub.

OK done that and rebooted and now I am in KL_full2fr new Zorin running, but now in RAM2 save on demand mode (i.e. nothing gets saved unless I run command save2flash). The save folder (upper_changes) gets automatically created as /sessions/upper_changes in that UUID 424d8f42-e835-4111-9053-dd086b3d38e8 partition I had created.

EDIT: oops... then discovered I wasn't in RAM2 mode afterall, but still in RAM0 no persistence mode... sigh.... Guess why? - answer: well, I previously did the /etc/grub.d/40_custom editing whilst in RAM0 no persistence mode (how daft of me) so when I rebooted into full install mode the 40_custom was the old one so update-grub changed nothing. So actually proves RAM0 mode works as it should hahaha. Okay, so once in full install mode I then did all of the above again and then ran command update-grub (which needs to be done in full install mode since I'm using full install grub2 here) and rebooted. Now I am really in RAM2 save on demand mode. All going well!

EDIT2: Here is the altered grub2 menu stanza:
I
menuentry "KLfull2fr_Zorin16_3" {
insmod ext2
search --no-floppy --fs-uuid --set 7a5ce698-a720-4dd7-bffe-3783573d1bc0
linux /KLfull2fr_Zorin16_3/vmlinuz w_bootfrom=UUID=7a5ce698-a720-4dd7-bffe-3783573d1bc0=/KLfull2fr_Zorin1603 w_changes=UUID=424d8f42-e835-4111-9053-dd086b3d38e8=/sessions w_changes1=RAM2 w_bottom=full2fr
initrd /KLfull2fr_Zorin16_3/initrd.gz
}

https://www.tinylinux.info/
DOWNLOAD wd_multi for hundreds of 'distros' at your fingertips: viewtopic.php?p=99154#p99154
Αξίζει να μεταφραστεί;

User avatar
wiak
Posts: 4069
Joined: Tue Dec 03, 2019 6:10 am
Location: Packing - big job
Has thanked: 65 times
Been thanked: 1200 times
Contact:

Re: KL your full installed distro (can use either)

Post by wiak »

Note that in such scenarios as my immediately above post you don't really need to use update-grub method, which the full install uses to regenerate its actually used /boot/grub/grub.cfg. You could just edit that /boot/grub/grub.cfg file directly. I just don't like doing it that way since prefer the designed-in /etc/grub.d/... arrangement and methodology.

https://www.tinylinux.info/
DOWNLOAD wd_multi for hundreds of 'distros' at your fingertips: viewtopic.php?p=99154#p99154
Αξίζει να μεταφραστεί;

User avatar
wiak
Posts: 4069
Joined: Tue Dec 03, 2019 6:10 am
Location: Packing - big job
Has thanked: 65 times
Been thanked: 1200 times
Contact:

Re: KL your full installed distro (can use either)

Post by wiak »

I may well be the only one using this single script to make alternative grub2 stanza to allow my normal full installed mainstream distro as a frugal install (whilst still able, via original grub menu stanza, to instead run it as normal full install), but it's a life-saver for my dev habits. So when doing non-dev work I sometimes still use normal full installed Linux Mint since stores all new additions and upgrades easily. But more often I now generally run same Linux Mint root filesystem in KL frugal mode in w_changes=RAM2 mode so changes go into separate upper_changes folder when I want them to. One effect is that I appear to have two different Linux Mint installs cos KL is same Linux Mint rootfs exactly but with upper_changes simply overlayed on top as a read/write layer.

Right now, in between being busy with other pressing matters, I'm working on a simple script that automatically gpt partitions a usb stick (or SD or any device really) and sets up grub2 on it. I got fed up with doing it manually even when helped by various Puppy Linux utilities - why Re these so complex???...just run simple script I feel.... I don't know if my script will work though... seems too simple compared to all the rest, but the partitioning part does work fine. I'm making three partitions tho I could easily change that: one very small fat32 boot_bios partition, one fat32 EFI Sytem partition, and rest of drive a Linux formatted partition. Not sure when I'll have it finished. End result should be like wd_grubconfig but just make grub2 installed media. I'm not planning to automate the grub2.cfg making at this stage since easy to just edit the default on usb stick provided grub.cfg with additions suggested by wd_grubconfig reports.

https://www.tinylinux.info/
DOWNLOAD wd_multi for hundreds of 'distros' at your fingertips: viewtopic.php?p=99154#p99154
Αξίζει να μεταφραστεί;

User avatar
wiak
Posts: 4069
Joined: Tue Dec 03, 2019 6:10 am
Location: Packing - big job
Has thanked: 65 times
Been thanked: 1200 times
Contact:

Re: KL your full installed distro (can use either)

Post by wiak »

The usb grub maker will have to wait. I've run out of time. Probably back to such stuff sometime coming March.

https://www.tinylinux.info/
DOWNLOAD wd_multi for hundreds of 'distros' at your fingertips: viewtopic.php?p=99154#p99154
Αξίζει να μεταφραστεί;

User avatar
wiak
Posts: 4069
Joined: Tue Dec 03, 2019 6:10 am
Location: Packing - big job
Has thanked: 65 times
Been thanked: 1200 times
Contact:

Re: KL your full installed distro (can use either)

Post by wiak »

Last week in early wd_multi experiments I accidentally made an error in the script. I was also stupidly running the testing/under-dev script on my full installed Linux Mint system, despite my warnings/disclaimer to others about doing that kind of risky thing.. Well... I was punished and accidentally wrote over the filesystem of much of my Linux Mint full install such that it needed re-installed. That taught me the lesson I already know.

Today, I am wiser... and using KL_full2frugal, which on boot uses the underlying full installed Linux Mint distro, but overlays a FirstRib initrd.gz driven upper_changes save folder and so on on top. Safe at last!

Unfortunately, following my own simple KL_full2frugal install instructions didn't work out-of-the-box for me...

For some reason I haven't thought much about since, the vmlinuz of Linux Mint wasn't copied correctly out of the Linux Mint /boot folder into my KL_full2frugal frugal install directory. I'm in too much of a hurry to work out why at the moment so just manually opened Mint /boot, found the vmlinuz, and copied it across manually.

Then I updated my grub config with the config_grub.txt suggested UUID stanza, but changed the default w_changes from RAM0 (no persistence) to RAM2 save on demand mode.

Alas, when I tried to reboot it hung saying too many levels of symbolic links... Hmmm, I remember seeing that issue during the facility's development, but couldn't remember what it was. Well... what it was... was me not reading my own instructions, which carefully explain that with full2frugal booting w_changes save folder has to be in a different partition from the Linux Mint full installed root filesystem...

So I had to change:

linux /KL_full2frugal/vmlinuz w_bootfrom=UUID=000c8c2a-764a-4bea-bc93-9e41eca3d9a1=/KL_full2frugal w_changes=RAM2 w_bottom=full2fr

to:

linux /KL_full2frugal/vmlinuz w_bootfrom=UUID=000c8c2a-764a-4bea-bc93-9e41eca3d9a1=/KL_full2frugal w_changes=UUID=7a5ce698-a720-4dd7-bffe-3783573d1bc0=/ w_changes1=RAM2 w_bottom=full2fr

where, as you can see, w_bootfrom UUID is a different partition from w_changes UUID so All is Fine Now, upper_changes saves are going to different partition, and I am posting this in my nice safe Linux Mint being used in a KL_full2frugal mode and with w_changes1=RAM2 save on demand mode!

Another reason I wanted into this KL_full2frugal boot is that I want to make it work with wd_convert2multi cos I fancy having tons of instances of my full installed Linux Mint distro, but all running in FirstRib save on demand RAM2 mode, whilst sharing the underlying Linux Mint full install filesystem... I've still to try that or make any mods that might be required to make it work, but will soon.

So much power with so much better safety - it is great to be in Control!!! Hopefully won't so easily destroy my full install system now - with multi-instances I'll have plenty to use if any break of course.

https://www.tinylinux.info/
DOWNLOAD wd_multi for hundreds of 'distros' at your fingertips: viewtopic.php?p=99154#p99154
Αξίζει να μεταφραστεί;

User avatar
wiak
Posts: 4069
Joined: Tue Dec 03, 2019 6:10 am
Location: Packing - big job
Has thanked: 65 times
Been thanked: 1200 times
Contact:

Re: KL your full installed distro (can use either)

Post by wiak »

When I'm trying to do something complicated for my brain... I often resort first to pen and paper. Hacking away on computer only is a bad way to code IMO...

Attachments
WILL_IT_WORK.jpg
WILL_IT_WORK.jpg (78.02 KiB) Viewed 2605 times

https://www.tinylinux.info/
DOWNLOAD wd_multi for hundreds of 'distros' at your fingertips: viewtopic.php?p=99154#p99154
Αξίζει να μεταφραστεί;

User avatar
wiak
Posts: 4069
Joined: Tue Dec 03, 2019 6:10 am
Location: Packing - big job
Has thanked: 65 times
Been thanked: 1200 times
Contact:

Re: KL your full installed distro (can use either)

Post by wiak »

Frankly, despite my on paper musings above, I could not work out if wd_convert2multi my KLfull2frugal of my underlying full installed Linux Mint would work! The amount of factors coming into play was just too mind-boggling!

In fact, the way KLfull2frugal itself works is itself pretty mind-boggling, and despite being the person who wrote FirstRib build system scripts including FR initrd, KLfull2frugal, and the recent wd_multi and wd_convert2multi, there are times (no matter how much coffee I've drunk) that I struggle to believe my ideas are going to do what I hope... In fact, I myself was astounded when wd_multi actually worked, despite tons of careful thought and pen and paper and studying every aspect of my FR initrd code. That was an ambitious, but good day.

Well, sometimes, when my brain simply can't fathom all the inter-related processes in play in complex FR initrd usage scenarios, I just kind of touch wood and trust in the logic of all the parts seeming to usually work - a kind of long test of inherent correctness in their logic... I thus gave up with my pen and paper on this occasion and just tried it:

1. Used KLfull2frugal to create a frugal install of my underlying Linux Mint. Got that working.
2. Created a folder /Mint_multi in my full install Linux Mint partition (the partition where /KLfull2frugal frugal install was also now sitting...).
3. Used my filemanager (thunar) to Copy /KLfull2frugal install directory into /Mint_multi and then renamed that /Mint_multi/KLfull2frugal directory to /Mint_multi/KLfull2frugal.MKL (per wd_config2multi --help).
4. I then put copy of executable wd_config2multi script into that /Mint_multi directory and ran command:

Code: Select all

./wd_convert2multi 10

The above certainly did build ten instance folders (instance0 to instance9) and these looked per my other wd_convert2multi tests (albeit no such complex KLfull2frugal case tried before...). I then checked the auto-created config_grub.txt file and the stanza looked fine, except was for w_changes=RAM2 mode and I know that KLfull2frugal installs need the savefolder in a separate partition to the underlying Linux Mint install. I thus changed the stanza to use w_changes=RAM0 (no persistence) mode instead and booted. IT BOOTED!!! :-) Then:

instead of using w_changes=RAM0 I used:

w_bootfrom=UUID=000c8c2a-764a-4bea-bc93-9e41eca3d9a1=/Mint_multi/KL_full2frugal/instance1 w_changes=UUID=7a5ce698-a720-4dd7-bffe-3783573d1bc0=/ w_changes1=RAM2 w_bottom=full2fr

which causes save folder to be at different UUID partition...

I booted and I'm now posting from instance1. Bedtime story is now over. It works.... and frankly I am shocked again. Unbelievable to me, but I am delighted no extra coding was required in wd_convert2multi, even for this complex Linux Mint full install to frugal to multi-instance scenario...

Attachments
wd_convert2multi_of_KLfull2frugalLINUXMINT.jpg
wd_convert2multi_of_KLfull2frugalLINUXMINT.jpg (110.79 KiB) Viewed 2604 times

https://www.tinylinux.info/
DOWNLOAD wd_multi for hundreds of 'distros' at your fingertips: viewtopic.php?p=99154#p99154
Αξίζει να μεταφραστεί;

libertas
Posts: 67
Joined: Thu Apr 22, 2021 8:35 pm
Has thanked: 9 times
Been thanked: 2 times

Re: KL your full installed distro (can use either)

Post by libertas »

Hi,

Would this KL installation work in a full disk encryption setup (Devuan using grub)?

User avatar
wiak
Posts: 4069
Joined: Tue Dec 03, 2019 6:10 am
Location: Packing - big job
Has thanked: 65 times
Been thanked: 1200 times
Contact:

Re: KL your full installed distro (can use either)

Post by wiak »

wiak wrote: Sat Sep 23, 2023 6:59 am

instead of using w_changes=RAM0 I used:

w_bootfrom=UUID=000c8c2a-764a-4bea-bc93-9e41eca3d9a1=/Mint_multi/KL_full2frugal/instance1 w_changes=UUID=7a5ce698-a720-4dd7-bffe-3783573d1bc0=/ w_changes1=RAM2 w_bottom=full2fr

which causes save folder to be at different UUID partition...

I booted and I'm now posting from instance1. Bedtime story is now over. It works.... and frankly I am shocked again. Unbelievable to me, but I am delighted no extra coding was required in wd_convert2multi, even for this complex Linux Mint full install to frugal to multi-instance scenario...

Whilst the above is absolutely true and correct and very useful for someone like me who "underneath" is often running a normal full install of Linux Mint (which I can then run also as a frugal install - as if a second distro - simply be using KL_full2fr mechanism), there is the problem that the end structure is somewhat different from a 'normal' FR/KL distro. An unfortunate side-effect of that is that the save2flash, the snapmergepuppy part of that, does not work with a KL_full2fr implementation. No problem to run in RAM2 mode - just that snapmergepuppy script no use this time. Main reason it doesn't work is that instead of main rootfs being the likes of 07KLV-Airedale.sfs, it is a full installed to main partition big Linux and not mounted to /mnt/layers in typical FirstRib fashion...

However, I do run in w_changes1=RAM2 mode, but I just use a simple rsync script (like i used to use with WDL_Arch some years ago). Now, I understand from @fredx181 who has studied all the things that can go wrong with missing whiteouts or bits and pieces left behind such that his implementation of snapmergepuppy uses a find mechanism and feeds lists to add and remove to rsync and goes as far as checking through all the addon (sfs's and so on) to see if whiteout name matches any layer's internal file. But, all I'm using is simple/simplistic-no-doubt-with-issues rsync command:

Code: Select all

sudo rsync -axHAXS --exclude={"/tmp/*","/run/*","/mnt/*","/media/*"} /mnt/layers/RAM/upper_changes/ /mnt/layers/uc_ro/

(using sudo cos in KL_full2fr underlying big Linux is run as normal user of course).

Most of the time, to be honest, I'm using KL_full2fr boot to test new stuff without bothering to save2flash anyway (though am booting in RAM2 mode), but I sometimes add new apps and run the above rsync line, and for that purpose all seems to work fine, and I do simple file deletions and run same rsync and still fine (results in char whiteout in uc_ro (i.e. external upper_changes savefolder).

BUT... since I have really not studied any like alone all of the implications of what can be expected to go wrong with that simple rsync (and the side-effects of overlayfs layers and whiteouts and so on in using rsync), I'd really like those who know (meaning @fredx181, for example) to give me some examples to try that will result in failure. I have no doubt such can be suggested, but I'd love to know all the overall issues that need to be addressed to iron out such flaws. Having said that, for now, I'm fine, but clearly advise great caution from anyone else choosing to use that simple rsync line for save2flash... Having said that, you can try it in KLV-Airedale too... but not one you rely on - just for an experimental test please...! It tends to be super fast, but goodness knows what junk it leaves lying around that I don't know about!... having said that, it does no harm at all to my underlying full install of Linux Mint since I am writing nothing to that, just to the savefolder...

Anyway, despite probable disaster facing my save2flash simplicity, it is amazing what we get away with sometimes. A truth table of some sort showing related problem cases would be great (since the basis of any algorithm/code).

https://www.tinylinux.info/
DOWNLOAD wd_multi for hundreds of 'distros' at your fingertips: viewtopic.php?p=99154#p99154
Αξίζει να μεταφραστεί;

User avatar
fredx181
Posts: 2997
Joined: Tue Dec 03, 2019 1:49 pm
Location: holland
Has thanked: 364 times
Been thanked: 1272 times
Contact:

Re: KL your full installed distro (can use either)

Post by fredx181 »

wiak wrote:

sudo rsync -axHAXS --exclude={"/tmp/*","/run/*","/mnt/*","/media/*"} /mnt/layers/RAM/upper_changes/ /mnt/layers/uc_ro/

That leaves whiteout files in upper_changes from files you once created, then (after reboot(s) ) same files deleted (leftover, useless whiteout files). I've found that complications/conflicts can happen then.
We had conversation about that some time ago, if I remember well.
Perhaps the snapmergepuppy script can be more simplified or/and compact, (everytime I look at it after some time, I'm having trouble to understand :D ) but from what I tested (many user cases, and on DebianDog too, it has similar code) that it works ok. (and it works fast too, at least for me).

Clarity
Posts: 3777
Joined: Fri Jul 24, 2020 10:59 pm
Has thanked: 1597 times
Been thanked: 512 times

Re: KL your full installed distro (can use either)

Post by Clarity »

wiak wrote: Sat Sep 23, 2023 6:32 am

When I'm trying to do something complicated for my brain... I often resort ...

YES! 8-)
I still resort to flowcharting. Use to have a flowcharting program in the past for DOS - Windows, but has been lost over time. So pen-paper offer a solution.

I should investigate a recommendation for Linux as this would provide an electronic way to save them as I often lose the paper from time to time. :lol:

moplop
Posts: 7
Joined: Fri Dec 15, 2023 3:32 pm
Has thanked: 5 times
Been thanked: 8 times

Re: KL your full installed distro (can use either)

Post by moplop »

Clarity wrote: Sat Apr 20, 2024 4:33 am
wiak wrote: Sat Sep 23, 2023 6:32 am

When I'm trying to do something complicated for my brain... I often resort ...

YES! 8-)
I still resort to flowcharting. Use to have a flowcharting program in the past for DOS - Windows, but has been lost over time. So pen-paper offer a solution.

I should investigate a recommendation for Linux as this would provide an electronic way to save them as I often lose the paper from time to time. :lol:

Freemind and Freeplane are both on Sourceforge and compatible with just about everything. Freeplane is constantly updated and is a bit more of a knowledge base, Freemind is dead simple and has been feature complete since 2014.

Post Reply

Return to “KL_full2fr”