Persistence not working on some versions

Please reproduce your error on a second machine before posting, and check the error by running without saved changes or extra modules (See FAQ No. 13, "How to report a bug"). For unstable Porteus versions (alpha, beta, rc) please use the relevant thread in our "Development" section.
steve6375
White ninja
White ninja
Posts: 16
Joined: 06 Mar 2012, 14:40
Location: Oxford

Persistence not working on some versions

Post#1 by steve6375 » 17 Feb 2014, 13:03

If I create an empty ext2 filesystem on \dev\sdb3 and the boot the KDE version from an ISO under grub4dos, it finds the porteus volume and uses it for persistence. It all works fine.
However if I substitute the ISO for the XFCE or RazorQT iso, it does not mount the sdb3 partition and I don't get persistence even though the same cheat code changes=/porteus is used inside the ISO.
If I use changes=LABEL:porteus/ then this works for all porteus ISOs. So does changes=/dev/sdb3.

Why does the KDE ISO detect the porteus volume and mount and use it but the XFCE and RazorQT versions do not?

User avatar
fanthom
Moderator Team
Moderator Team
Posts: 5666
Joined: 28 Dec 2010, 02:42
Distribution: Porteus Kiosk
Location: Poland
Contact:

Re: Persistence not working on some versions

Post#2 by fanthom » 18 Feb 2014, 21:18

If I create an empty ext2 filesystem on \dev\sdb3 and the boot the KDE version from an ISO under grub4dos, it finds the porteus volume and uses it for persistence. It all works fine.
by default linuxrc (booting script) searches for /porteus folder (changes=/porteus cheatcode) and /dev/sdb3 is empty so it cant be used for persistence until you change to 'changes=/dev/sdb3'
Why does the KDE ISO detect the porteus volume and mount and use it but the XFCE and RazorQT versions do not?
they work exactly the same. the only difference between them is GUI (003-desktop_name.xzm).

please boot to KDE4 and generate xpsinfo report. do the same for XFCE, link both here and i'll reveal the mystery.
Please add [Solved] to your thread title if the solution was found.

steve6375
White ninja
White ninja
Posts: 16
Joined: 06 Mar 2012, 14:40
Location: Oxford

Re: Persistence not working on some versions

Post#3 by steve6375 » 19 Feb 2014, 11:12

In both cases directly boots from .iso file mounted as sda4 and uses first menu entry in ISO (running from VBox session directly from USB Flash drive on host system as sda)...
KDE4 using blank porteus ext2 volume in \dev\sda3 is at http://pastebin.ca/2644115
XFCE using blank porteus ext2 volume in \dev\sda3 is at http://pastebin.ca/2644116

In 2644116 it says 'changes are stored in memory' - yet boot conditions were the same except I used an XFCE ISO (ext2 filesystem was freshly made before each boot)
This line is missing from the XFCE boot log...
Feb 19 10:55:04 porteus kernel: [ 14.380197] EXT4-fs (sda3): re-mounted. Opts: (null)

User avatar
brokenman
Site Admin
Site Admin
Posts: 6105
Joined: 27 Dec 2010, 03:50
Distribution: Porteus v4 all desktops
Location: Brazil

Re: Persistence not working on some versions

Post#4 by brokenman » 19 Feb 2014, 13:44

You should also explain that your booting KDE-v2.1 and XFCE-v3.0rc2
How do i become super user?
Wear your underpants on the outside and put on a cape.

steve6375
White ninja
White ninja
Posts: 16
Joined: 06 Mar 2012, 14:40
Location: Oxford

Re: Persistence not working on some versions

Post#5 by steve6375 » 19 Feb 2014, 14:34

Both ISOs (KDE4 and XFCE) where downloaded on 14 Feb using the Builder wizard. I assumed they were the same.

Looking inside the KDE4 ISO, it has folder dates of 2013-07-06, so I guess it must be an old version though not sure how that happened!

I re-downloaded KDE4 v3.0 rc2 and that also does not see the porteus volume (as expected by you)

So this seems to be a bug in v3 that was not present in v.2?

bkmo
Ronin
Ronin
Posts: 2
Joined: 19 Feb 2014, 16:09
Distribution: Porteus XFCE V3
Location: Costa Rica

Re: Persistence not working on some versions

Post#6 by bkmo » 19 Feb 2014, 16:15

I would not call it a bug, as it is working correctly as documented. It would be nice if the V3.x would act as the V2.x did. I would be happy if it was defaulted to use a partition with a label of "porteus" as the persistence, or "changes" partition. This seems to be how it worked in V2.x, and works with many other Linux distros. Just my 2 cents.

User avatar
fanthom
Moderator Team
Moderator Team
Posts: 5666
Joined: 28 Dec 2010, 02:42
Distribution: Porteus Kiosk
Location: Poland
Contact:

Re: Persistence not working on some versions

Post#7 by fanthom » 19 Feb 2014, 20:57

So this seems to be a bug in v3 that was not present in v.2?
2.x was searching for '/porteus' folder across all partitions and first one found was used for persistence. this was causing troubles for users who have 2+ porteus installations, ie. XFCE+KDE4 as changes were mixed. in 3.0 i have implemented new rule which is documented in the changelog:

Code: Select all

- Check booting media in first place when searching for changes
in your case 3.0 never save changes as you are booting from ISO9660 filesystem.

solution:
give a full path to folder where changes should be saved, ie 'changes=/mnt/sda3/porteus-changes'
Please add [Solved] to your thread title if the solution was found.

steve6375
White ninja
White ninja
Posts: 16
Joined: 06 Mar 2012, 14:40
Location: Oxford

Re: Persistence not working on some versions

Post#8 by steve6375 » 20 Feb 2014, 11:54

In v2, if I have an empty ext2 filesystem file (filename=/porteus) on the NTFS USB boot drive (no folders or files inside it) which has a volume label of 'ssp' then persistence works (even though no folder porteus is created). This is using the standard ISO with changes=/porteus. So it has mounted the porteus file as an ext2 filesystem http://pastebin.ca/2644685
In v3 this does not work.

In v3, if I use changes=LABEL:porteus/ then an empty ext2 filesystem on sdb3 (no folders or files inside it) which has a volume label of 'porteus' = persistence works (again no folder porteus exists).

So it does not seem to need a folder called porteus at all.

In v3, even if I create a porteus folder in /dev/sdb3 ext2 partition and use the unchanged ISO (with changes=/porteus inside) I still don't get persistence. It is not using the /porteus folder on /dev/sdb3.

If I create a porteus folder on sdb1 (NTFS USB boot drive), persistence does not work either.

User avatar
fanthom
Moderator Team
Moderator Team
Posts: 5666
Joined: 28 Dec 2010, 02:42
Distribution: Porteus Kiosk
Location: Poland
Contact:

Re: Persistence not working on some versions

Post#9 by fanthom » 20 Feb 2014, 18:01

if I have an empty ext2 filesystem file (filename=/porteus)
ok - i get you. never expected that one can create a file named porteus (usually it's porteus.dat) but this is still valid from linuxrc point of view as it checks for both: files and dirs.

In v3 this does not work.
yes - and i have explained this before:
a) linuxrc checks booting media first
b) finds /porteus folder on it
c) finds that it's read only
d) fallbacks to memory for saving changes

if you want to save changes somewhere else than booting media then you have to give a path like: 'changes=/mnt/sdb3/porteus'
Please add [Solved] to your thread title if the solution was found.

bkmo
Ronin
Ronin
Posts: 2
Joined: 19 Feb 2014, 16:09
Distribution: Porteus XFCE V3
Location: Costa Rica

Re: Persistence not working on some versions

Post#10 by bkmo » 20 Feb 2014, 18:18

fanthom wrote:if I have an empty ext2 filesystem file (filename=/porteus)
ok - i get you. never expected that one can create a file named porteus (usually it's porteus.dat) but this is still valid from linuxrc point of view as it checks for both: files and dirs.
V3 will not find and use "porteus.dat" automatically without changing the porteus.cfg will it?

steve6375
White ninja
White ninja
Posts: 16
Joined: 06 Mar 2012, 14:40
Location: Oxford

Re: Persistence not working on some versions

Post#11 by steve6375 » 20 Feb 2014, 18:29

OK, but when booting from USB it may not always be /dev/sdb (depends on number of internal hard disks) so using changes=LABEL: is preferable.

How is the ISO intended to work if a CD is booted from? Surely the changes=/porteus would not work from a CD so what is the point of it? It would make more sense to change it to 'changes=LABEL:porteus-rw/' ???

The documentation should make it clear that for changes it will only look on the boot partition unless a specific device is specified or a LABEL: or UUID: cheatcode.
http://www.porteus.org/component/conten ... -them.html

... If you use a file image instead of a device, and the image
contains a valid filesystem, Porteus will mount it on a loop
device and will store changes to it.
... If you use a directory, Porteus will save changes to it (it
will make a 'changes' subdirectory there). This should only
be used for linux filesystems, if changes need to be saved to a
FAT or NTFS partition, a savefile container has to be used.

User avatar
fanthom
Moderator Team
Moderator Team
Posts: 5666
Joined: 28 Dec 2010, 02:42
Distribution: Porteus Kiosk
Location: Poland
Contact:

Re: Persistence not working on some versions

Post#12 by fanthom » 20 Feb 2014, 21:40

V3 will not find and use "porteus.dat" automatically without changing the porteus.cfg will it?
there is no porteus version which would find it automatically as our default cheatcode is 'changes=/porteus' which is not the same as 'changes=porteus.dat'

when booting from USB it may not always be /dev/sdb (depends on number of internal hard disks) so using changes=LABEL: is preferable.
i would say that UUID is preferable as it's easy to change LABEL (double click under windows) and break changes cheatcode. changing UUID is not that easy and usually is done by formating.

Surely the changes=/porteus would not work from a CD so what is the point of it?
i believe that majority of porteus installations are done on USB/hd where this cheatcode makes sense.
btw: optical media are matter of the past.

It would make more sense to change it to 'changes=LABEL:porteus-rw/'???
surely not and i hope i dont have to explain why

The documentation should make it clear that for changes it will only look on the boot partition unless a specific device is specified or a LABEL: or UUID: cheatcode.
this statement would be true if you write it as:
The documentation should make it clear that for default changes cheatcode it will only look on the boot partition unless a specific device is specified or a LABEL: or UUID: cheatcode.
why did i bold 'default'? because if you change it to 'changes=fanthom-rulez' then this folder/file wont be found on the booting media and linuxrc will search top level of all partition till it finds one.

btw: 99% of people do not boot from ISO burnt on a partition like you do and default 'changes=/porteus' just works for them. if you want exotic setup the you are obligated to read our documentation (well - actually everyone is so we wont have to answer the same questions 1000 times).
Please add [Solved] to your thread title if the solution was found.

steve6375
White ninja
White ninja
Posts: 16
Joined: 06 Mar 2012, 14:40
Location: Oxford

Re: Persistence not working on some versions

Post#13 by steve6375 » 20 Feb 2014, 23:00

You said
this was causing troubles for users who have 2+ porteus installations, ie. XFCE+KDE4 as changes were mixed.
So did they have one installation on one partition and one installation on another partition? If so, why not change the algorithm to look on the boot partition for /porteus first and then search other partitions if not found or not writeable - in a flat file install, wouldn't the 'local' porteus folder always be found and used for changes and thus no mixing would occur?

User avatar
francois
Contributor
Contributor
Posts: 6434
Joined: 28 Dec 2010, 14:25
Distribution: xfce plank porteus nemesis
Location: Le printemps, le printemps, le printemps... ... l'hiver s'essoufle.

Re: Persistence not working on some versions

Post#14 by francois » 21 Feb 2014, 00:05

@steve:
Why don't you simply try the frugal install? :crazy:
Prendre son temps, profiter de celui qui passe.

User avatar
brokenman
Site Admin
Site Admin
Posts: 6105
Joined: 27 Dec 2010, 03:50
Distribution: Porteus v4 all desktops
Location: Brazil

Re: Persistence not working on some versions

Post#15 by brokenman » 21 Feb 2014, 01:52

If so, why not change the algorithm to look on the boot partition for /porteus first and then search other partitions if not found or not writeable
That is precisely what has been done. I believe this was explained earlier in thread. It would be nice to find a fool proof way to implement changes so that nothing needs to be done by the user, but this is a long shot. There are too many variations of booting structures so we have to cater to the majority.
How do i become super user?
Wear your underpants on the outside and put on a cape.

Post Reply