How to make a "DIY" Immutable Pup installation

Issues and / or general discussion relating to Puppy

Moderator: Forum moderators

Post Reply
User avatar
peebee
Posts: 1636
Joined: Mon Jul 13, 2020 10:54 am
Location: Worcestershire, UK
Has thanked: 157 times
Been thanked: 714 times
Contact:

How to make a "DIY" Immutable Pup installation

Post by peebee »

Lots of chatter in the Linux world about Immutable distros.........
e.g. https://itsfoss.com/immutable-linux-distros/

Puppy Linux is by design mainly immutable but this topic is to provide advice on How-To make a fully immutable install of Puppy Linux. It assumes a modern Woof-CE built version of Puppy Linux (e.g. with bdrv support). This is a "DIY" guide - i.e. it involves a number of manual steps - it does not produce an "Immutable OS" only an "Immutable Installation" of Puppy.

The How-To will be expanded / edited from any comments received.

How-To make an Immutable installation of Puppy Linux

  1. make a normal frugal install of Puppy
  2. edit the boot stanza to include pmedia=ataflash (or usbflash)
  3. boot into the new Puppy and make any configuration changes you need: e.g. location, timezone, keyboard, wifi, firewall, sound levels etc.
  4. load any extra sfs you require, but rename the sfs to have version independent names - e.g. chromium.sfs, thunderbird.sfs so they can be replaced with later versions without breaking immutability.
  5. using System -> Event manager -> Save session - set the Save interval to 0 and tick "Ask at shutdown whether to save session"
  6. reboot and create a save folder

then from another install of Puppy, or the same install but booted with pfix=ram

  1. rename the save folder to bdrv_****
  2. using pcompress (right click on bdrv folder), create a bdrv_****.sfs
  3. create an empty save folder with the name noted at 1.
  4. reboot into your new immutable system
  5. do various activities
  6. reboot but "Do not save" session
  7. check that the empty save folder remains empty

if you need to make additional configuration changes (3.), reinstate the bdrv folder as the save folder, boot into the system, make the changes, reboot saving the changes, remake the bdrv.sfs with pcompress

Builder of LxPups, SPups, UPup32s, VoidPups; LXDE, LXQt, Xfce addons; Chromium, Firefox etc. sfs; & Kernels

User avatar
peebee
Posts: 1636
Joined: Mon Jul 13, 2020 10:54 am
Location: Worcestershire, UK
Has thanked: 157 times
Been thanked: 714 times
Contact:

Re: How to make an Immutable Pup

Post by peebee »

reserved

Builder of LxPups, SPups, UPup32s, VoidPups; LXDE, LXQt, Xfce addons; Chromium, Firefox etc. sfs; & Kernels

User avatar
peebee
Posts: 1636
Joined: Mon Jul 13, 2020 10:54 am
Location: Worcestershire, UK
Has thanked: 157 times
Been thanked: 714 times
Contact:

Re: How to make an Immutable Pup

Post by peebee »

reserved

Builder of LxPups, SPups, UPup32s, VoidPups; LXDE, LXQt, Xfce addons; Chromium, Firefox etc. sfs; & Kernels

williwaw
Posts: 1939
Joined: Tue Jul 14, 2020 11:24 pm
Has thanked: 170 times
Been thanked: 368 times

Re: How to make an Immutable Pup

Post by williwaw »

a worthwhile look into how puppy can be made more immutable, thanks.

does compressing the renamed savefolder make it read only?

9. create an empty save folder with the name noted at 7.

does the empty save folder have to be recoginized by the init as a save folder? If so, doesn't it have to follow certian naming conventions?
a different example of naming besides bdrv_**** could be more instructive

dimkr
Posts: 2420
Joined: Wed Dec 30, 2020 6:14 pm
Has thanked: 53 times
Been thanked: 1202 times

Re: How to make an Immutable Pup

Post by dimkr »

A typical immutable distro allows atomic update, rollback and other things. You can't market a live boot Puppy as an immutable distro unless it gains these features.

User avatar
peebee
Posts: 1636
Joined: Mon Jul 13, 2020 10:54 am
Location: Worcestershire, UK
Has thanked: 157 times
Been thanked: 714 times
Contact:

Re: How to make an Immutable Pup

Post by peebee »

dimkr wrote: Sun Oct 08, 2023 6:18 pm

A typical immutable distro allows atomic update, rollback and other things. You can't market a live boot Puppy as an immutable distro unless it gains these features.

update = replace any of the sfs with an updated version
rollback = revert any of the sfs to a previous version

Builder of LxPups, SPups, UPup32s, VoidPups; LXDE, LXQt, Xfce addons; Chromium, Firefox etc. sfs; & Kernels

dimkr
Posts: 2420
Joined: Wed Dec 30, 2020 6:14 pm
Has thanked: 53 times
Been thanked: 1202 times

Re: How to make an Immutable Pup

Post by dimkr »

That's a "poor man's immutable distro" or a "DIY immutable distro" with bad user experience :)

Dry Falls
Posts: 80
Joined: Thu Jul 29, 2021 7:40 pm
Has thanked: 22 times
Been thanked: 43 times

Re: How to make an Immutable Pup

Post by Dry Falls »

dimkr wrote: Mon Oct 09, 2023 6:28 am

That's a "poor man's immutable distro" or a "DIY immutable distro" with bad user experience :)

Curious. Can you explain what you mean by "bad user experience"? Sounds like a trite dismissal to me. There are lots of ways built into puppy (as you are well aware) to run in ram with personal configurations built in. Rootfs used in fatdog with drives unmounted at boot is another. Taersch and NicOs have offered similar solutions to the above. Perhaps you only have an objection to the word "immutable". If you want to be Aristotelian, true stasis does not exist in nature so those big (respectable?) distros are also misusing the term.

df

dimkr
Posts: 2420
Joined: Wed Dec 30, 2020 6:14 pm
Has thanked: 53 times
Been thanked: 1202 times

Re: How to make an Immutable Pup

Post by dimkr »

Immutable distros have an update tool that updates the OS on reboot, a tool that allows a user to roll back an update on reboot, applications running inside containers, and so on. You can achieve all these things in a "read-only" installation of Puppy, but only if you do this manually: you need to boot with pfix=copy, create a backup of your SFSs and swap SFSs to update, back up your save file/folder all the time (so you can roll back both OS updates and changes to the persistent parts of the OS), install Flatpak, and so on.

People who want an immutable distro and find Puppy because it's described as a lightweight immutable distro will be disappointed because it doesn't have any tools for these things, and some core principles of an immutable distro (like read-only /usr) don't apply Puppy.

(I know what "immutable" means, and yes, a live boot Puppy is "immutable". What I'm saying is, the thing people expect when they hear "immutable distro" is not a "live distro": it's a distro that allows atomic updates, etc'. Ask yourself which features listed in https://fedoraproject.org/silverblue/ and https://vanillaos.org/ are also provided by your save-less Puppy.)

User avatar
peebee
Posts: 1636
Joined: Mon Jul 13, 2020 10:54 am
Location: Worcestershire, UK
Has thanked: 157 times
Been thanked: 714 times
Contact:

Re: How to make an Immutable Pup installation

Post by peebee »

thread title changed

Builder of LxPups, SPups, UPup32s, VoidPups; LXDE, LXQt, Xfce addons; Chromium, Firefox etc. sfs; & Kernels

User avatar
Marv
Posts: 451
Joined: Fri Dec 20, 2019 3:09 am
Has thanked: 212 times
Been thanked: 120 times

Re: How to make an Immutable Pup installation

Post by Marv »

Since I haven't run anything other than Puppy for the last decade at least the distinction was lost on me. Just a DIY chap here. I like to scrutinize changes and not commit til I'm happy with the changes when I'm updating/changing something in my working OS so manually updating SFS, portables, kernel, desktop configuration, symlinks etc. and saving the result to a y (or b) drv when I'm comfortable with the result works for me. I still run pups with savefiles for some of my users but my daily for quite a while now is a 'poor mans immutable'.

My pups: LxPupSc64 and Voidpup64 with LXDE ydrv and synaptics touchpad drivers, both using small savefiles for customizations. Ydrv based NoblePup64 and Fossapup64-small (both LXDE/PCManFM with no savefiles). No fdrvs throughout. :thumbup2:

Post Reply

Return to “Users”