changes=EXIT: manual update

Post here if you are a new Porteus member and you're looking for some help.
Post Reply
User avatar
Ed_P
Contributor
Contributor
Posts: 3409
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 3.2.2 64-bit ISO
Location: Western NY, USA

changes=EXIT: manual update

Post#1 by Ed_P » 05 Oct 2015, 04:32

changes=EXIT: works great when shutting down Porteus but is there a way to manually perform the save function without shutting down? A command or script that updates the save.dat file the same way the changes=EXIT: cheatcode works.

I'm looking to save USM updates to the save.dat file without the shutdown/reboot senario. Sometimes the updates take a while to complete.
Ed

donald
Full of knowledge
Full of knowledge
Posts: 1243
Joined: 17 Jun 2013, 13:17
Distribution: Porteus 3.2.2 XFCE 32bit
Location: Germany

Re: changes=EXIT: manual update

Post#2 by donald » 05 Oct 2015, 04:56

While you are running a session with changes=EXIT, you can use the
'dump-session' command (run as root from the command line) to move all
of your changes from RAM to your storage media.

found in cheatcodes.txt.. :wink:

User avatar
Ed_P
Contributor
Contributor
Posts: 3409
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 3.2.2 64-bit ISO
Location: Western NY, USA

Re: changes=EXIT: manual update

Post#3 by Ed_P » 05 Oct 2015, 05:47

:good: Thank you donald. :beer:
donald wrote:found in cheatcodes.txt.. :wink:
I didn't look in that file, but I did look in the FAQ write ups here on the board. Honest. But couldn't find it. :oops:
Ed

User avatar
Ed_P
Contributor
Contributor
Posts: 3409
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 3.2.2 64-bit ISO
Location: Western NY, USA

Re: changes=EXIT: manual update

Post#4 by Ed_P » 06 Oct 2015, 03:13

It didn't work donald!!

I boot, update USM, do a dump-session, reboot, updates lost.

Code: Select all

root@porteus:/home/guest# dump-session
syncing what's left in buffers
saving changes to /mnt/sdb1/changes/porteussave.dat - this may take a while...
clearing RAM
session saved
root@porteus:/home/guest# usm -v
 You are using USM version:  3.1.9

root@porteus:/home/guest#
Reboot

Code: Select all

guest@porteus:~$ su
Password: 
root@porteus:/home/guest# usm -v
 You are using USM version:  3.1.7

root@porteus:/home/guest# 
bootmode

Code: Select all

root@porteus:/home/guest# ./bootmode.sh
Boot device: /mnt/sdb1
OS: Porteus-v3.0.1
ARCH: x86_64
Kernel: Linux porteus 3.14.15-porteus
quiet \boot\syslinux\vmlinuz from=UUID:F789-E55C extramod=UUID:F789-E55C/Modules;UUID:F789-E55C/modsavedat volume=33 reboot=cold changes=EXIT:UUID:F789-E55C/changes/porteussave.dat initrd=boot\syslinux\initrd.xz
root@porteus:/home/guest# 
Ed

donald
Full of knowledge
Full of knowledge
Posts: 1243
Joined: 17 Jun 2013, 13:17
Distribution: Porteus 3.2.2 XFCE 32bit
Location: Germany

Re: changes=EXIT: manual update

Post#5 by donald » 06 Oct 2015, 23:44

Hi Ed
That's a pity!

--> changes=EXIT: works great <--> does that mean that the USM updates were stored??

Then you have the 'dump-session' command used, and thereafter rebooted,
and the updates were lost.

now I do have a problem with the logic.
Even if the 'dump-session' did not work, the updates would then be stored at reboot.
(because of the changes=EXIT cheatcode)
Or were the updates never saved?

Bogomips
Full of knowledge
Full of knowledge
Posts: 2563
Joined: 25 Jun 2014, 15:21
Distribution: 3.2.2 Cinnamon & KDE5
Location: London

Re: changes=EXIT: manual update

Post#6 by Bogomips » 07 Oct 2015, 01:15

Have been having some sort of problem with usm not being updated. If you try saving something else, does the same occur?
Linux porteus 4.4.0-porteus #3 SMP PREEMPT Sat Jan 23 07:01:55 UTC 2016 i686 AMD Sempron(tm) 140 Processor AuthenticAMD GNU/Linux
NVIDIA Corporation C61 [GeForce 6150SE nForce 430] (rev a2) MemTotal: 901760 kB MemFree: 66752 kB

User avatar
Ed_P
Contributor
Contributor
Posts: 3409
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 3.2.2 64-bit ISO
Location: Western NY, USA

Re: changes=EXIT: manual update

Post#7 by Ed_P » 07 Oct 2015, 01:56

Hi guys. :beer:

Well, the situation deepens. I found that NO updates, of any kind, were being saved. :shock: Even simple adds of bookmarks to FF. And the problem is my USB configuration with my rEFInd menu. :wall:

On my USB drive I have:

Code: Select all

guest@porteus:~$ ls -l /mnt/sdb1
total 44
drwxrwxrwx 11 root root 4096 Sep 12 14:59 Backups/
drwxrwxrwx  3 root root 4096 Sep  5 23:29 EFI/
drwxrwxrwx  2 root root 4096 Oct  4 23:27 Modules/
drwxrwxrwx  4 root root 4096 Sep  5 23:40 My_Webpages/
drwxrwxrwx  2 root root 4096 Sep 15 00:01 System\ Volume\ Information/
drwxrwxrwx  4 root root 4096 Oct  5 01:53 Temp/
-rwxrwxrwx  1 root root 1141 Jan 30  2015 USB_INSTALLATION.txt*
drwxrwxrwx  4 root root 4096 Sep  5 23:29 boot/
drwxrwxrwx  2 root root 4096 Oct  4 19:56 changes/
drwxrwxrwx  2 root root 4096 Oct  6 00:28 modsavedat/
drwxrwxrwx  6 root root 4096 Jan 30  2015 porteus/
guest@porteus:~$ ls -l /mnt/sdb1/changes
total 327680
-rwxrwxrwx 1 root root 335544320 Oct  6 00:42 porteussave.dat*
guest@porteus:~$ ls -l /mnt/sdb1/modsavedat
total 327680
-rwxrwxrwx 1 root root 335544320 Oct  6 00:30 porteussave.dat.xzm*
With the porteusave.dat.xzm a copy of my normal porteussave.dat file with the .xzm extention added.

My default boot configuration with the USB drive is to Porteus with a config that has all my changes but without the ability to make changes and have them saved. (Helpful for when the grandkids use a netbook to play games.) Rather than have the changes=EXIT cheatcode I use the extramod= cheatcode with the porteussave.dat.xzm file added on.

Code: Select all

options "from=UUID:F789-E55C extramod=UUID:F789-E55C/Modules;UUID:F789-E55C/modsavedat volume=33 reboot=cold" 
When I want to save changes I boot and use a submenuentry menu that I thought/hoped would override the extramod= cheatcode in the default options parameter.

Code: Select all

	submenuentry "Save changes" {
		add_options "extramod=UUID:F789-E55C/Modules changes=EXIT:UUID:F789-E55C/changes/porteussave.dat" 
    }
I have found that that does not override the override the extramod= cheatcode in the default options parameter.

IF I delete/rename the modsavedat .xzm file and reboot to the Save changes menu saving changes works. Changes are saved when exiting Porteus and when using the dump-session command.

So, at this point I don't know if I need another cheatcode, a different cheatcode, a different rEFInd menu option, a different dump-session command, etc. At least I know what the problem is, and that's half the battle.
Ed

User avatar
Ed_P
Contributor
Contributor
Posts: 3409
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 3.2.2 64-bit ISO
Location: Western NY, USA

Re: changes=EXIT: manual update

Post#8 by Ed_P » 07 Oct 2015, 03:48

This arrangement seems to be working.

Code: Select all

	options "from=UUID:F789-E55C extramod=UUID:F789-E55C/Modules;UUID:F789-E55C/modsavedat volume=33 reboot=cold" 
	submenuentry "Save changes" {
		add_options "changes=EXIT:UUID:F789-E55C/changes/porteussave.dat   noload=porteussave.dat.xzm"
    }
Will watch it do a few days to be sure. :)
Ed

Post Reply