Porteus don't save the changes

Post here if you are a new Porteus member and you're looking for some help.
nicoamtab
Ronin
Ronin
Posts: 3
Joined: 19 Oct 2024, 21:07
Distribution: porteus 5.01

Porteus don't save the changes

Post#1 by nicoamtab » 20 Oct 2024, 10:20

Dear I have recently discovered Porteus Kde, of which I really appreciated its speed and lightness, but I was blocked by a problem that has already been submitted to you by others. I was unable to save the changes, nor the modules as the filesystem is read-only. I tried in vain to change the permissions with CHMOD. I read the FAQs but I couldn't get to the bottom of it. I also wanted to set up the "Language Selection Tool" for the Italian language, but it has no other languages besides English. Could you please help me in the easiest way possible? Me to totally new to linux. Thank you Nicholas

User avatar
Ed_P
Contributor
Contributor
Posts: 8663
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

Porteus don't save the changes

Post#2 by Ed_P » 20 Oct 2024, 16:33

Hi Nicholas
nicoamtab wrote:
20 Oct 2024, 10:20
totally new to linux. Thank you Nicholas
We all were at some point. :happy62:

So, where did you install Porteus? Harddrive or USB drive? If to your harddrive, do you run Windows on the harddrive? I occasionally run into the problem you've experienced and find rebooting to Windows and running a "chkdsk /f" command for the drive resolves the problem when I reboot to Porteus.

If you installed to a USB drive that is formatted as FAT32, or exFAT, you have to create a save.dat file to save changes. And for modules, on my FAT32 USB drive I create a folder outside of the /porteus one , usually named /Modules, and store my xzm modules in it. Both these tweaks require tweaks to the /boot/syslinux/porteus.cfg file, the "APPEND changes" line needs to be changed.

User avatar
ncmprhnsbl
DEV Team
DEV Team
Posts: 4126
Joined: 20 Mar 2012, 03:42
Distribution: v5.0-64bit
Location: australia
Contact:

Porteus don't save the changes

Post#3 by ncmprhnsbl » 21 Oct 2024, 00:54

nicoamtab wrote:
20 Oct 2024, 10:20
Could you please help me in the easiest way possible?
if you could post the contents of /var/log/porteus-livedbg (it's just a text file you can open and copy/paste from), that should provide most of the information we need to help, thanks.
Forum Rules : https://forum.porteus.org/viewtopic.php?f=35&t=44

nicoamtab
Ronin
Ronin
Posts: 3
Joined: 19 Oct 2024, 21:07
Distribution: porteus 5.01

Porteus don't save the changes

Post#4 by nicoamtab » 23 Oct 2024, 13:02

Ed_P wrote:
20 Oct 2024, 16:33
Both these tweaks require tweaks to the /boot/syslinux/porteus.cfg file, the "APPEND changes" line needs to be changed.
First of all, thank you for answering me. I installed Porteus on an EXT4 formatted USB drive using the linuxmint tool. I try to create a new savefile using the Porteus savefile manager but I get an error message that there is not enough space on /mnt/sdc. The flash drive has a capacity of 16 gb. Can I create a second partition on the usb interface where I can save modules and changes?

nicoamtab
Ronin
Ronin
Posts: 3
Joined: 19 Oct 2024, 21:07
Distribution: porteus 5.01

Porteus don't save the changes

Post#5 by nicoamtab » 23 Oct 2024, 13:04

ncmprhnsbl wrote:
21 Oct 2024, 00:54
if you could post the contents of /var/log/porteus-livedbg (it's just a text file you can open and copy/paste from), that should provide most of the information we need to help, thanks.
# Recognized devices:
/dev/mmcblk0p1: UUID="FC30-3DA9" TYPE="vfat"
/dev/sda2: UUID="D51C-975C" TYPE="vfat"
/dev/sda3: UUID="9fcfaba2-ccea-4d21-a739-978394285120" TYPE="ext4"
/dev/sdb1: LABEL="Angela" UUID="BC60AC6760AC2A5A" TYPE="ntfs"
/dev/sdb5: LABEL="Cristina" UUID="86DED304DED2EC05" TYPE="ntfs"
/dev/sdc: LABEL="Porteus" TYPE="iso9660"
/dev/sdc1: LABEL="Porteus" TYPE="iso9660"
/dev/sdd1: LABEL="VERBATIM" TYPE="vfat"
/dev/sdd2: UUID="56E7CE635E4ADC7B" TYPE="ntfs"

beny
Full of knowledge
Full of knowledge
Posts: 2216
Joined: 02 Jan 2011, 11:33
Location: italy

Porteus don't save the changes

Post#6 by beny » 23 Oct 2024, 16:05

bash-5.2# ls
base changes create-iso.sh modules optional porteux.cfg rootcopy
bash-5.2#
porteux or porteus is the same if you don't have the changes directory make it into the porteus tree and APPEND like the boot entry when you boot changes are saved

this is the init4 entry you can also use the txt mode, that you have into the /boot/syslinux directory
LABEL graphical
MENU LABEL Graphics Mode
KERNEL /boot/syslinux/vmlinuz
INITRD /boot/syslinux/initrd.zst
APPEND changes=/porteux

User avatar
Ed_P
Contributor
Contributor
Posts: 8663
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

Porteus don't save the changes

Post#7 by Ed_P » 23 Oct 2024, 16:22

nicoamtab wrote:
23 Oct 2024, 13:02
I installed Porteus on an EXT4 formatted USB drive using the linuxmint tool.
I've never used the linuxmint tool so no idea what it does. But on a EXT4 partition you shouldn't need to create a save.dat file. Adding a /changes folder to the USB drive and changing the /boot/syslinux/porteus.cfg file's APPEND line to look similar to the one beny posted should be enough.

APPEND changes=/changes

beny
Full of knowledge
Full of knowledge
Posts: 2216
Joined: 02 Jan 2011, 11:33
Location: italy

Porteus don't save the changes

Post#8 by beny » 23 Oct 2024, 16:31

Ed_P APPEND changes=/changes, you have no root tree path, better changes=/porteus or porteux or maybe i am wrong..

User avatar
Ed_P
Contributor
Contributor
Posts: 8663
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

Porteus don't save the changes

Post#9 by Ed_P » 23 Oct 2024, 22:31

An interesting point beny. I normally boot USBs with a single partition. If the drive has 2 partitions with /porteus on the 2nd one how does booting know where the /porteus folder is?

And putting the /changes folder in the /porteus folder might resolve the root tree issue for /changes.

User avatar
ncmprhnsbl
DEV Team
DEV Team
Posts: 4126
Joined: 20 Mar 2012, 03:42
Distribution: v5.0-64bit
Location: australia
Contact:

Porteus don't save the changes

Post#10 by ncmprhnsbl » 23 Oct 2024, 23:49

nicoamtab wrote:
23 Oct 2024, 13:04
/dev/sdc: LABEL="Porteus" TYPE="iso9660"
/dev/sdc1: LABEL="Porteus" TYPE="iso9660"
(btw, that's not the entire /var/log/porteus-livedbg)
if that's what you're booting from, i guess that the linuxmint tool just "burns" the ISO to the disk overwriting any existing partition(s)(effectively turning the usb into a readonly cd)
to make a proper porteus frugal install, you'll need to format and repartition your usb (via mint if that's what you have), then mount the ISO or use an archiving tool to then copy the folders present to the usb, then in a terminal cd to <usb>/boot and run Porteus-installer-for-linux.com ..
more detailed instructions in USB_INSTALLATION.txt in the root of the ISO and /boot/docs/install.txt
Forum Rules : https://forum.porteus.org/viewtopic.php?f=35&t=44

Amaya Nidjit
White ninja
White ninja
Posts: 19
Joined: 01 Nov 2024, 05:53
Distribution: porteus-v5.0-i586 XFCE

Porteus don't save the changes

Post#11 by Amaya Nidjit » 23 Nov 2024, 07:21

@ncmprhnsbl:
The mistake Nicholas made is a forced error. Several sources on the web say you can't just copy files from inside the ISO, they say you HAVE to use a burn tool the way nicoamtab did. For most persistent portable distros (eg Slitaz), to get a persisting OS, you have to first burn a USB stick as the provided iso9660 (read-only) filesystem, boot from it, and install to another USB stick using the in-OS installer that creates a writable filesystem. PITA.
One of the very cool features of Porteus is not having to do this. But it is unexpected and unusual, and contrary to prevailing general advice.
I really DON'T understand why distros are still being distributed as ISOs instead of images of writable filesystems, since nobody uses optical disks any more. Even Windows has tools available that will write an image as easily as writing an ISO.
Ed_P wrote:
23 Oct 2024, 22:31
If the drive has 2 partitions with /porteus on the 2nd one how does booting know where the /porteus folder is?
I'd like to know the answer to that too. I know it works effortlessly because I am booting a Porteus installation from the second partition (ext4) of a USB stick (the first partition is fat32) and it works fine. It might just be that the partition its booted on is the first place vmlinuz looks?

Actually, maybe the more specific question should be: How the heck does booting even know its supposed to look for a /porteus folder in the first place? Is there a syslinux cfg file that tells the kernel what to search for? Or is it compiled into the particular kernels shipped with Porteus?

Amaya

User avatar
ncmprhnsbl
DEV Team
DEV Team
Posts: 4126
Joined: 20 Mar 2012, 03:42
Distribution: v5.0-64bit
Location: australia
Contact:

Porteus don't save the changes

Post#12 by ncmprhnsbl » 29 Nov 2024, 02:46

Amaya Nidjit wrote:
23 Nov 2024, 07:21
For most persistent portable distros (eg Slitaz), to get a persisting OS, you have to first burn a USB stick as the provided iso9660 (read-only) filesystem, boot from it, and install to another USB stick using the in-OS installer that creates a writable filesystem. PITA.
and porteus can be installed this way too, but as you say: PITA :)
another way is to boot the iso in (a properly configured) VirtualBox with usb access via the host and install that way.
and from another linux at least, most? archive managers can open an iso like any other archive, from there, extract directly to the usb..
from what i've seen of the .img format, is that while their simpler to install for those who don't want to bother with partitioning and so on, they're slightly more cumbersome for those who don't want the prepackaged approach..
and once you've understood the nature of the frugal install, life's so much simpler..
Amaya Nidjit wrote:
23 Nov 2024, 07:21
Actually, maybe the more specific question should be: How the heck does booting even know its supposed to look for a /porteus folder in the first place? Is there a syslinux cfg file that tells the kernel what to search for? Or is it compiled into the particular kernels shipped with Porteus?
short answer: initrd.xz
slightly longer answer: within initrd.xz (which is the first thing loaded by the kernel at bootup, creating an "initial filesystem" in ram) there are scripts linuxrc and some functions: finit
when linuxrc runs at boot it, among other things, looks for porteus files(modules and such) by finding the porteus*.cfg file.
you easily view these initrd files in the live system at /mnt/live/
Forum Rules : https://forum.porteus.org/viewtopic.php?f=35&t=44

User avatar
Ed_P
Contributor
Contributor
Posts: 8663
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

Porteus don't save the changes

Post#13 by Ed_P » 29 Nov 2024, 05:24

ncmprhnsbl wrote:
29 Nov 2024, 02:46
and porteus can be installed this way too, but as you say: PITA :)
another way is to boot the iso in (a properly configured) VirtualBox with usb access via the host and install that way.
Another option is to download the iso and boot the iso file directly via grub2. :happy62: Been doing it for years. :)

rych
Warlord
Warlord
Posts: 733
Joined: 04 Jan 2014, 04:27
Distribution: Porteus 5.0 x64 OpenBox
Location: NZ
Contact:

Porteus don't save the changes

Post#14 by rych » 29 Nov 2024, 10:44

ncmprhnsbl wrote:
29 Nov 2024, 02:46
short answer: initrd.xz
slightly longer answer: within initrd.xz (which is the first thing loaded by the kernel at bootup, creating an "initial filesystem" in ram) there are scripts linuxrc and some functions: finit
when linuxrc runs at boot it, among other things, looks for porteus files(modules and such) by finding the porteus*.cfg file.
you easily view these initrd files in the live system at /mnt/live/

My linuxrc has this section

Code: Select all

	if [ $FROM ]; then
		locate -e $FROM/porteus/$CFG
		if [ $? -eq 0 ]; then
			DIR=`echo $LPTH | rev | cut -d/ -f3- | rev`; [ $DIR ] && FOLDER=$DIR/porteus
		else
			echo -e "${YELLOW}from= cheatcode is incorrect, press enter to search through all devices${RST}"
			read -s; search -e porteus/$CFG
		fi
	else
		search -e porteus/$CFG || lazy -e porteus/$CFG
	fi
I think it calls this function from finit

Code: Select all

# Search for boot location
search() { FND=none; for x in `ls /mnt | tac`; do
[ $1 /mnt/$x/$2 ] && { DEV=$x; FND=y; break; }; done
[ $FND = y ]; }
I don't claim to fully understand this code, but it confirms that a porteus folder will be found even if we don't help it with a FROM cheatcode.

Amaya Nidjit
White ninja
White ninja
Posts: 19
Joined: 01 Nov 2024, 05:53
Distribution: porteus-v5.0-i586 XFCE

Porteus don't save the changes

Post#15 by Amaya Nidjit » 04 Dec 2024, 03:55

ncmprhnsbl wrote:
29 Nov 2024, 02:46
Short answer: initrd.xz
slightly longer answer: within initrd.xz ... you easily view these initrd files in the live system at /mnt/live/
Thanks for the explaination. I wondered if it was something like that, a specific written instruction by DEVs.
It helps to have it explained. I find it really hard to follow the code in those scripts - I'm too old to learn THAT new trick. I think the last time I tried programming anything (or following the meaning of coding) was in GWBASIC on a 286 - back when that was a snazzy machine.

Amaya

Post Reply