SFS-Exec

Miscellaneous tools
Post Reply
Message
Author
seaside
Posts: 934
Joined: Thu 12 Apr 2007, 00:19

SFS-Exec-pupsave-noshut

#81 Post by seaside »

Maybe we can kill many birds with one stone.

Here's "SFS-Exec-pupsave-noshut" which is a pure "save to the pupsave only". No poweroff - just save.

This version locks down every door to the pupsave file (probably overkill) so that any process that tries to write to the pupsave file will fail. No reboot will save to the pupsave file.

See first post for "SFS-Exec-pupsave-noshut.pet"

Cheers,
s
NOTE: I forgot to mention that this version provides the opportunity to back up your pupsave file with no risk of corruption because it has been made "read-only"

Jasper

#82 Post by Jasper »

Hi seaside,

Thank you very much for your "SFS-Exec-pupsave-noshut" which is a pure "save to the pupsave only". No poweroff - just save.

It had (for me) a few side effects, perhaps because of the way I installed it; but for anyone else who tries it - I'd suggest (merely as a sensible precaution) backup your current save file before installing and using that save pet.

The side effects were 5.25 reverted to Openbox whereas I had switched to JWM, your sfs loader stopped working and Firefox (my default browser) offered to import some settings.

My regards

Personally I like the non-corruption facet; but I much prefer having the normal save at intervals/reboot/power-off as well. nooby knows of some forum members who are likely to be interested. Also, it's 3.45 a.m. here so I'm going to do a nooby and hit the sack.

nooby
Posts: 10369
Joined: Sun 29 Jun 2008, 19:05
Location: SwedenEurope

#83 Post by nooby »

Wow indeed. By all means let the imagination run wild and sooner or later this will be really cool. I wish I understood what is going on better.

I should first make a trusty copy of my current pupsavefile and then install your new thing and that would allow me to save without being shut down.

And this save is would unfortunately change some things as Jasper noticed so that maybe has to be sorted out.

Seaside any clue why his FF suddenly thought it started anew? Not good. :)

But I love that you are at it. Wish me could contribute. It is very exciting.

Re "why your program operates differently in 431 and 525."

As I remember one of the two main guys making Lupu525 wrote in that thread that 525 are different so one need to get it at that level because he did warn that one need to be aware of that.

So maybe one should list which Puppy that is best to experiment with.

1. Seaside use Puppy 431 mainly.
2. Jasper test on oops sorry have forget.
3. Nooby test mainly on Snowpup that has both Lupu511 and Lupu525 base.

Puppies in the 5 series seems to be different enough to run into some trouble
So we need to find a puppy derivate of 431 that I can use on my computer or I have to wait until you Seaside get more fond of develop for the 511 or 525 versions :)

I will eat now and then test on Snow using a copy of snow renamed to Snowsfs
I use Google Search on Puppy Forum
not an ideal solution though

nooby
Posts: 10369
Joined: Sun 29 Jun 2008, 19:05
Location: SwedenEurope

#84 Post by nooby »

This link is important?
http://www.murga-linux.com/puppy/viewto ... 325#371325
2byte describe it thus:
A tiny gtkdialog utility for backing up the live pupsave file. You no longer need to reboot with pfix=ram in order to backup the savefile. Lots of built-ins and safety features make it very "oops" proof.

Auto-detects the current savefile.
Generates the backup file name with the date and time appended.
Checks the available space for the backup file.
Will not perform the backup if anything is incorrect.
Displays real-time status and progress feedback.
Supports 2fs and 3fs save file types.

It's easy fast and works very well.
So maybe we have to read there or even ask him if he has tested it on Lupu525?
I use Google Search on Puppy Forum
not an ideal solution though

Jasper

#85 Post by Jasper »

Hi nooby,

seaside has contributed to the "important" thread linked in your post immediately above. Further, it seems that method is not always totally safe from corruption.

I saw somewhere that you have tested seaside's "sfs" program(s) on 5 different Puppy versions.

Since you want to contribute here, your best efforts might be just testing this new super-safe save pet on your many Puppy versions and reporting here what, if any, side effects you noticed on each version tried.

My regards

nooby
Posts: 10369
Joined: Sun 29 Jun 2008, 19:05
Location: SwedenEurope

#86 Post by nooby »

Seaside the most unusual error did happen.
I tried to find sfs-exec-shutdown in ppm but it was not there in Fluppy13 that I test on

So I got two save buttons and could not decide which is which so I deleted the one that shut the computer totally off and kept the new one that only save without any shut down.

That took away sfs-exec from ROX and it made teh sfs-exec to refuse to start FF.sfs

So I tried to delete the savefile to put in the old savefile there and start all over but then this one poppedup
fluppy13s/.fuse_hidden0000000300000002

Is that something that Jemimah has built in or did you add the fuse whatever a fuse is? I go do pfix=ram instead but much work to change everything that Jemimah think is the best for me :) Double click and such

oops yes I should go for finding out.
I guess I have to make a list of which puppy is not 511 or 525.

Snow 5 is 513 and Snow 16 is 525
Lighthouse seems to be based on 420 so that is a good target to practice on.

Fluppy seems to be based on 430? so that would be a good one too.

Maybe fluppy is the one that can confirm what Seaside says about 511 and up being different. So I go for preparing a Fluppy now to do the test on my computer to see what happens.
I use Google Search on Puppy Forum
not an ideal solution though

Jasper

#87 Post by Jasper »

Hi seaside,

I am delighted with your "SFS-Exec" and your original "save and power-off" pets and, personally, I neither need nor ask for any changes.

However, whilst I have not the least understanding of what may be practicable; it may (most highly improbably, just may) please all of the users all of the time if the blue save icon were made into a right click menu.

So that say,

In off mode it would show a large red cross (flashing or static) on the blue background and any auto save setting would be set to zero and it would be impossible to save by any normal method (with or without any useful additional reminder note).

In super-save mode there would be a large green tick on the blue background indicating that it is safe to save (and/or backup to any location) on-the-fly (without prospective corruption) and any timer setting would be reset to zero and no other normal save method would be available.

In normal save mode there would be the original blue desktop icon, but a save interval could be set as preferred (perhaps even superimposed on the icon) and the normal save would take place on a menu reboot or power-off as well as adhoc use of this mode.

My regards

nooby
Posts: 10369
Joined: Sun 29 Jun 2008, 19:05
Location: SwedenEurope

#88 Post by nooby »

Haha Seaside I am so sorry. I was wrong and you where very right :)

One need to do it the way you described. To not save a pupsave before installing sfs-exec-noshut So now that thing works but still ...

I still fail to get what is supposed to not get saved?

I installed a pet and that one are still there after reboot. That is not supposed to happen on a puppy431 Fluppy flavor OS when I do just a reboot is it? The pet should just go int o RAM and then get flushed at reboot?
I use Google Search on Puppy Forum
not an ideal solution though

seaside
Posts: 934
Joined: Thu 12 Apr 2007, 00:19

#89 Post by seaside »

nooby wrote:
I still fail to get what is supposed to not get saved?

I installed a pet and that one are still there after reboot. That is not supposed to happen on a puppy431 Fluppy flavor OS when I do just a reboot is it? The pet should just go int o RAM and then get flushed at reboot?
Nooby,

After you have installed the "SFS-Exec-pupsave-noshut.pet", saved to the pupsave file and rebooted, could you post the results of typing in a terminal "mount".

This might help to discover what's happening.

Regards,
s

nooby
Posts: 10369
Joined: Sun 29 Jun 2008, 19:05
Location: SwedenEurope

#90 Post by nooby »

Maybe you mean before I start using firefox to be able to answer you?

Okay I do the cli now.
# mount
rootfs on / type rootfs (rw,relatime)
/dev/sda3 on /initrd/mnt/dev_save type fuseblk (rw,noatime,user_id=0,group_id=0,default_permissions,blksize=4096)
/dev/loop1 on /initrd/pup_rw type ext3 (rw,noatime,errors=continue,barrier=0,data=ordered)
tmpfs on /initrd/mnt/tmpfs type tmpfs (rw,relatime,size=149600k)
/dev/loop0 on /initrd/pup_ro2 type squashfs (ro,noatime)
unionfs on / type aufs (rw,relatime,si=43ca2dd3)
tmpfs on /tmp type tmpfs (rw,relatime,size=256212k)
tmpfs on /mnt/unrootfs type tmpfs (rw,relatime,size=4096k)
none on /proc type proc (rw,relatime)
none on /dev/pts type devpts (rw,relatime,gid=2,mode=620)
none on /sys type sysfs (rw,relatime)
none on /proc/bus/usb type usbfs (rw,relatime)
none on /dev/shm type tmpfs (rw,relatime)
#
That fuse file what is that?
I use Google Search on Puppy Forum
not an ideal solution though

seaside
Posts: 934
Joined: Thu 12 Apr 2007, 00:19

#91 Post by seaside »

Nooby,

Thanks, that was very helpful and one more request post what is in the file "/etc/rc.d/PUPSTATE".

Regards,
s
(I have no idea what the "fuse' refers to - I don't have that on any of my mounts :) )

nooby
Posts: 10369
Joined: Sun 29 Jun 2008, 19:05
Location: SwedenEurope

#92 Post by nooby »

Don't get alarmed me have fluppy13s

The s stands for sfs and flp is Jemimah's way to say Fluppy
here it is

PUPMODE=12
PDEV1='sda3'
DEV1FS='ntfs'
PUPSFS='sda3,ntfs,/fluppy13s/flp-013.sfs'
PUPSAVE='sda3,ntfs,/fluppy13s/flpsave.3fs'
PMEDIA='scsihd'
#v3.97: kernel with libata pata has both sata and pata drives in ATADRIVES...
ATADRIVES='sda '
#these directories are unionfs layers in /initrd...
SAVE_LAYER='/pup_rw'
PUP_LAYER='/pup_ro2'
#The partition that has the flpsave file is mounted here...
PUP_HOME='/mnt/dev_save'
#(in /initrd) ...note, /mnt/home is a link to it.
#this file has extra kernel drivers and firmware...
ZDRV=''
#complete set of modules in the initrd (moved to main f.s.)...
ZDRVINIT='no'
PSWAPFILE=''
PSAVEMARK=''
FASTPARTS='sda1|ntfs sda2|ntfs sda3|ntfs '
I use Google Search on Puppy Forum
not an ideal solution though

seaside
Posts: 934
Joined: Thu 12 Apr 2007, 00:19

#93 Post by seaside »

Nooby,

Thanks. Your information confirms that some additional coding is required to test where the pupsave file is mounted.

Unfortunately it's not always the same and depends on what kind of installation.

So basically, in your case, the pupsave file was not changed to a "read-only" system which is what was intended.

Thanks for testing this and I'll have to ponder how to change this.

Regards,
s

nooby
Posts: 10369
Joined: Sun 29 Jun 2008, 19:05
Location: SwedenEurope

#94 Post by nooby »

Very naive question from Nooby. Can I not tell it to be ro through CLI then or even use a gui and set permissions and such :)
I use Google Search on Puppy Forum
not an ideal solution though

seaside
Posts: 934
Joined: Thu 12 Apr 2007, 00:19

#95 Post by seaside »

nooby wrote:Very naive question from Nooby. Can I not tell it to be ro through CLI then or even use a gui and set permissions and such :)
Nooby,

Yes, in some cases. Would you post just one more output. The contents of "/etc/rc.d/rc.local"?

Thanks,
s

nooby
Posts: 10369
Joined: Sun 29 Jun 2008, 19:05
Location: SwedenEurope

#96 Post by nooby »

#this file called from rc.sysinit
#you can edit this file
#When firewall is installed, will append lines to this file...
modprobe evdev

if [ -x /etc/rc.d/rc.firewall ]; then
/etc/rc.d/rc.firewall start
fi
mv /usr/sbin/snapmergepuppy /usr/sbin/snapmergepuppyHOLD
mount -o remount,ro /dev/loop1

Could it be that there is different loops to consider?

Sorry me so eager but not having knowledge for it.

Back when I tried out sfs-exec on Snowpup this did happen while preparing the preferences.

Did I tell you about my failure to change the background picture. It held a kind of copy of Snowpup's snowy Finland and I wanted a Cat or Dog there. And I changed the name of the file and renamed the cat file exactly same and placed it in right folder and so on. Nope the original file was copied over from the sfs or something. Could not be changed.

Could not something similar go on here. The pupsavefile we see is a copy and not the one one need to reach to change to ro and the one we see get copied unto the original that is rw when one reboot.

Just a wild totally long shot kind of hunch
I use Google Search on Puppy Forum
not an ideal solution though

seaside
Posts: 934
Joined: Thu 12 Apr 2007, 00:19

#97 Post by seaside »

Nooby,

Interesting. In a terminal if you type "mount -o remount,ro /dev/loop1 " and if successful then type "mount". does "/dev/loop1" show as "read-only" ( you can tell because it should look something like "(ro,noatime)" .

Regards,
s

nooby
Posts: 10369
Joined: Sun 29 Jun 2008, 19:05
Location: SwedenEurope

#98 Post by nooby »

# mount -o remount,ro /dev/loop1
mount: /initrd/pup_rw is busy
#
# mount
rootfs on / type rootfs (rw,relatime)
/dev/sda3 on /initrd/mnt/dev_save type fuseblk (rw,noatime,user_id=0,group_id=0,default_permissions,blksize=4096)
/dev/loop1 on /initrd/pup_rw type ext3 (rw,noatime,errors=continue,barrier=0,data=ordered)
tmpfs on /initrd/mnt/tmpfs type tmpfs (rw,relatime,size=149600k)
/dev/loop0 on /initrd/pup_ro2 type squashfs (ro,noatime)
unionfs on / type aufs (rw,relatime,si=43ca2dd3)
tmpfs on /tmp type tmpfs (rw,relatime,size=256212k)
tmpfs on /mnt/unrootfs type tmpfs (rw,relatime,size=4096k)
none on /proc type proc (rw,relatime)
none on /dev/pts type devpts (rw,relatime,gid=2,mode=620)
none on /sys type sysfs (rw,relatime)
none on /proc/bus/usb type usbfs (rw,relatime)
none on /dev/shm type tmpfs (rw,relatime)
#
I use Google Search on Puppy Forum
not an ideal solution though

seaside
Posts: 934
Joined: Thu 12 Apr 2007, 00:19

#99 Post by seaside »

nooby wrote:# mount -o remount,ro /dev/loop1
mount: /initrd/pup_rw is busy
#
The command "mount -o remount,ro /dev/loop1" should have remounted your pupsave file as "read-only" (ro) as it does with my tests. In your case, it failed to remount and I'm not sure why.

Thank you for testing.

Regards,
s

nooby
Posts: 10369
Joined: Sun 29 Jun 2008, 19:05
Location: SwedenEurope

#100 Post by nooby »

Tomorrow or some other day I test it on Quirky 1.4 to see how that goes.
I use Google Search on Puppy Forum
not an ideal solution though

Post Reply