The time now is Wed 27 Jan 2021, 12:46
All times are UTC - 4 |
Author |
Message |
shinobar

Joined: 28 May 2009 Posts: 2674 Location: Japan
|
Posted: Fri 17 Apr 2015, 18:38 Post subject:
Re: sfs_load-2.3.2 on pupmode=13 |
|
tnx mavrothal.
i am using sfs_load-2.3.2 on PUPMODE=13 and working with no problem so far.
_________________ Work around Puppy Linux http://shinobar.net/linux/puppy.html
|
Back to top
|
|
 |
mavrothal

Joined: 24 Aug 2009 Posts: 3108
|
Posted: Sat 18 Apr 2015, 01:40 Post subject:
|
|
Thx
Any ideas how to adapt it for pupmode 2?
It should be possible as aufs is there just the same.
Is it worth trying to integrate it with the current or maybe write a new script and have it called from sfs_load?
Best
_________________ == Here is how to solve your Linux problems fast ==
|
Back to top
|
|
 |
Argolance

Joined: 06 Jan 2008 Posts: 3822 Location: PORT-BRILLET (Mayenne - France)
|
Posted: Fri 05 Jun 2015, 05:58 Post subject:
|
|
Bonjour,
Please take a look around this thread...
sfs_load (2.3.2) seems to generate a (wrong) path starting with '/initrd/initrd/' (pupmode 5)
Cordialement.
_________________
Puppy Search
|
Back to top
|
|
 |
mavrothal

Joined: 24 Aug 2009 Posts: 3108
|
Posted: Fri 05 Jun 2015, 06:35 Post subject:
|
|
I did
_________________ == Here is how to solve your Linux problems fast ==
|
Back to top
|
|
 |
ASRI éducation

Joined: 09 May 2009 Posts: 3203 Location: France
|
Posted: Wed 08 Jul 2015, 11:14 Post subject:
|
|
sfs_load-2.3.0.pet
I used the latest version of shinobar 'sfs_load-2.3.pet (2014-09-06)'.
I have not integrated the mavrothal changes (v2.3.1/2.3.2) because testing is not finished.
Proposed changes for /usr/sbin/sfs_load
#20150706 v2.3.0 by ASRI: Increase the size of main GUI # Add info "number of sfs mounted" # For the list of mounted sfs, use a "table" (instead of "list") to sort the list alphabetically # Add button refresh
Regards
Code: | --- ./sfs_load_2.3 2014-09-06 10:44:34.000000000 +0200
+++ ./sfs_load_2.3.0 2015-07-07 16:06:31.000000000 +0200
@@ -51,9 +51,10 @@
#v2.1.9: fix loop device conflict with irregular initramfs
#2014-08-10 v2.2: fix was removed all sfs after abnormal shutdown
#2014-09-06 v2.3: fix again save-to-directry, avoid always mounted puppy sfs partition under PUPMODE=5
+#20150706 v2.3.0 by ASRI: Increase the size of main GUI # Add info "number of sfs mounted" # For the list of mounted sfs, use of a "table" (instead of "list") to sort the list alphabetically # Add button refresh
MYPATH=$0
MYNAME=$(basename "$0")
-VERSION=2.3
+VERSION=2.3.0
ORGOPT="$@"
#some options the puplet builder can choose
WIPEWHITEONINIT="true" # true/false
@@ -761,7 +762,18 @@
}
main_dialog() {
waitsplash $(gettext "Probing...")
- BOXHEIGHT=150
+ BOXHEIGHT1=300
+ BOXWIDTH=650
+ TEXTWIDTH=580
+ TEXTWIDTHCHARS=30
+ list="/tmp/sfs_load/loop_device_list"
+ cntsfsloaded=0
+ while read LINE
+ do
+ if [ "$LINE" != "" ]; then
+ cntsfsloaded=`expr $cntsfsloaded + 1`
+ fi
+ done < "$list"
LOADVISIBLE="enabled"
UNLOADVISIBLE="eabled"
if [ "$ACTION" = "unload" ]; then
@@ -793,8 +805,9 @@
UNLOADCOMBO=""
if [ "$ALREADY_SFS_LIST" != "" ]; then
UNLOADABLE="enabled"
- UNLOADCOMBO='<list tooltip-text="'$(gettext "Select the sfs file you want to unload.")'">
- <variable>UNLOADSFS</variable>'$(make_combo $ALREADY_SFS_LIST)'<visible>'$UNLOADVISIBLE'</visible></list>'
+ UNLOADCOMBO='<table tooltip-text="'$(gettext "Select the sfs file you want to unload.")'">
+ <label>'$(gettext 'Total of mounted SFS =')' '$cntsfsloaded'</label>
+ <variable>UNLOADSFS</variable>'$(make_combo $ALREADY_SFS_LIST)'<visible>'$UNLOADVISIBLE'</visible></table>'
[ "$QUEUELIST" ] && UNLOADCOMBO="$UNLOADCOMBO
"'<text><input>echo -en "'$(gettext "Some are not loaded but in the queue.")'"</input></text>'
else
@@ -804,10 +817,10 @@
DIALOG='<window title="'$LONG_TITLE'"><vbox>
<hbox>
<pixmap><input file>'$MYICON'</input></pixmap>
- <text width-chars="40"><input>echo -en "'$(gettext "You can load or unload extra SFS files on-the-fly.")'"</input></text>
+ <text width-chars="'$TEXTWIDTHCHARS'" width-request="'$TEXTWIDTH'"><input>echo -en "'$(gettext "You can load or unload extra SFS files on-the-fly.")'"</input></text>
</hbox>
- <hbox><frame '$(gettext "Load SFS")'>
- <vbox height-request="'$BOXHEIGHT'">
+ <hbox width-request="'$BOXWIDTH'"><frame '$(gettext "Load SFS")'>
+ <vbox height-request="'$BOXHEIGHT1'">
'"$LOADCOMBO
$WRONGTEXT"'
</vbox>
@@ -816,7 +829,7 @@
<action>EXIT:Load</action><visible>'$LOADVISIBLE'</visible></button>
</frame>
<frame '$(gettext "Unload SFS")'>
- <vbox height-request="'$BOXHEIGHT'">
+ <vbox height-request="'$BOXHEIGHT1'">
'$UNLOADCOMBO'
</vbox>
<button tooltip-text="'$(gettext "Which SFS do you want to unload?")' '$(gettext "Click here after you choose the extra sfs file.")'">
@@ -825,7 +838,8 @@
</frame></hbox>
<hbox>
- <button><label>'$(gettext 'Quit')'</label><input file stock="gtk-quit"></input><action>EXIT:Abort</action></button>
+ <button tooltip-text="'$(gettext "Refresh list of loaded sfs.")'"><input file stock="gtk-refresh"></input><action>sfs_load &</action><action>EXIT:Abort</action></button>
+ <button tooltip-text="'$(eval_gettext "Quit $TITLE v$VERSION.")'"><input file stock="gtk-quit"></input><action>EXIT:Abort</action></button>
</hbox>
</vbox></window>'
waitsplash --stop
|
 |
Description |
md5 ac2aaf2b4d6831f6923dd70ba39d9f31
|

Download |
Filename |
sfs_load-2.3.0.pet |
Filesize |
33.94 KB |
Downloaded |
382 Time(s) |
Description |
|
Filesize |
48.7 KB |
Viewed |
849 Time(s) |

|
_________________ Projet ASRI éducation => Association | Forum | Dépôt | Espace kids
|
Back to top
|
|
 |
Argolance

Joined: 06 Jan 2008 Posts: 3822 Location: PORT-BRILLET (Mayenne - France)
|
Posted: Fri 21 Aug 2015, 10:12 Post subject:
|
|
Bonjour,
When trying to load an SFS file that is different but has the same name of an already loaded SFS file, SFS_load says this SFS is already loaded and asks user if he wants to unload it.
If user wants to load the new one and then to copy or to move it to /initrd/mnt/dev_save, SFS_load just says SFS file "was found" but does not allow user to choose if he wants to keep the old one or to overwrite it with the new one.
Is it silly or could the script be modified beneficially in this way? I tried to test/do this myself but am a bit afraid to break something so much the script is complicated for me .
Cordialement.
_________________
Puppy Search
|
Back to top
|
|
 |
musher0
Joined: 04 Jan 2009 Posts: 15041 Location: Gatineau (Qc), Canada
|
Posted: Fri 21 Aug 2015, 11:11 Post subject:
|
|
Bonjour Argolance.
It could be a simple matter of adding a check in the script for size and/or date of the
sfs file.
But I think it is Linux itself (and maybe all OS's) that cannot handle two files of the same
name at the same time. This is a good way to confuse the system, let alone sfs-load.
First trick explained in The Hacker's Book, I think.
A question, though: if you're using sfs-load and you get that message, does that means
that you have already and gleefully squished the existing sfs by the same name?
This situation happens every second month with java JRE for example :
someone does a new sfs for the new java JRE, we unload the old one and we load
the new one. Simple. But of course the javas don't have the same version number.
À plus tard.
musher0
_________________ musher0
~~~~~~~~~~
"You want it darker? We kill the flame." (L. Cohen)
|
Back to top
|
|
 |
Argolance

Joined: 06 Jan 2008 Posts: 3822 Location: PORT-BRILLET (Mayenne - France)
|
Posted: Fri 21 Aug 2015, 12:08 Post subject:
|
|
Bonjour,
Thanks for replying, dear musher0
musher0 wrote: | cannot handle two files of the same name at the same time. |
I obviously do not intend to let user load two sfs files with the same name at the same time (for that strange purpose - probably useless - it is enough to name both differently), just replace the "old" one by the "new" one, which should be loaded at next startup. When SFS file is already present in /initrd/mnt/dev_save, SFS_load doesn't replace the old one with the new one, it just says that SFS file "was found" but keeps the old one that will be loaded at next startup anyway. If user chooses not to copy/move the SFS file to /initrd/mnt/dev_save, so there is no problem because the SFS file is directly loaded from the Downloads directory and the new one will be loaded at next startup. If it could be possible with moved/copied SFS files, using a dialog box prompting user if he wants or not do the overwriting, I think it would be convenient.
Cordialement.
_________________
Puppy Search
|
Back to top
|
|
 |
musher0
Joined: 04 Jan 2009 Posts: 15041 Location: Gatineau (Qc), Canada
|
Posted: Fri 21 Aug 2015, 14:08 Post subject:
|
|
Hello again, Argolance.
Je crois que ç'a à voir avec les couches / I think it has to do with the layers.
and you can't change an active layer mounted at /initrd/pup_ro-something without
un-mounting it first.
This layer is active, so removing it while it is active would be like cutting the branch
you are sitting on. The system will not let you do it.
On the other hand,
Code: | more /initrd/tmp/EXTRASFSS |
will tell you which sfs's are loaded at the moment in your Puppy, therefore which sfs
you must unload before mounting the new sfs.
From that list, it should be possible to write a script to
-- compare the names of the sfs's
-- unmount the old sfs and
-- mount the new one directly --
carefully, possibly bypassing sfs_load entirely.
(Not sure about this "bypassing").
Just a thought. / Une idée comme ça.
It needs testing, validation, of course -- and probably multiple checks in the script
in order not to "break" your system.
Autrement tu te retrouveras le bec à l'eau. / Otherwise you'll be left high and dry.
À+
musher0
_________________ musher0
~~~~~~~~~~
"You want it darker? We kill the flame." (L. Cohen)
|
Back to top
|
|
 |
Argolance

Joined: 06 Jan 2008 Posts: 3822 Location: PORT-BRILLET (Mayenne - France)
|
Posted: Fri 21 Aug 2015, 17:48 Post subject:
|
|
[EDIT]
Bonsoir,
Thank you musher0.
Quote: | This layer is active, so removing it while it is active would be like cutting the branch you are sitting on. The system will not let you do it. |
May be I am wrong, but you can delete a mounted SFS file and you will see that it will work properly during all the session because, as layer, it is not affected. The only difference is that it will not be mounted at next startup (with all the troubles this implies). Now, if you delete any file of the mounted SFS file with your file manager, Puppy will remember this and deleted files will not be present at next startup though the (new or old) SFS is duly mounted. Deletion affects the layer but not the SFS file itself (which is read-only anyway) and what could happen to the SFS file seems to be none of its business all long the session.
Quote: | Autrement tu te retrouveras le bec à l'eau. |
Not sure: I really think replacing an SFS with another one is possible while it is currently mounted (it is what my little experiment tends to "prove": I did it manually with my devx file and even with my main ToOpPy sfs file during all my tests and at next startup, as far as I know, all works fine). So, I admit I would like to have (also) the opinion of another "leading light" of the forum and learn, if "feasible", how to modify the SFS_load script properly, using some added command lines inside and with all the required precautions!
To sum up: I download a SFS file that has the same name as a SFS file present (loaded/mounted or not) in /initrd/mnt/dev_save. If I try to install/load the new SFS, 2 cases:
- if already mounted, SFS_load asks me if I want to unload it. So, I unload it, then I click the new one, choose "Install SFS", SFS_load says he found it, then doesn't load the new one but reload the old one.
- if not loaded/mounted, SFS_load says he found it and so on... I just would like the old one to be replaced by the new one and not to have to do it manually..
Suggestion: the button "Install SFS" should be labeled "Un/Install SFS" because user can uninstall/unload any SFS file this way too.
Cordialement.
_________________
Puppy Search
Last edited by Argolance on Sun 23 Aug 2015, 05:34; edited 5 times in total
|
Back to top
|
|
 |
musher0
Joined: 04 Jan 2009 Posts: 15041 Location: Gatineau (Qc), Canada
|
Posted: Sat 22 Aug 2015, 03:01 Post subject:
|
|
Hello Argolance.
Moi, a "leading light" among Puppyists?! Wow, that really is flattery! You must have a
favor to ask me!
I find you courageous to change the devx file "in vivo". I know that I wouldn't risk it!
If it works, bravo!
I did follow your reasoning, and I think it makes sense, but I am more conservative
than you are, so I'll stick with the traditional procedure for changing sfs's.
However, this may be of interest to you:
I remember that on another thread (mais lequel dans le capharnaüm du forum ! / but
which one in this mess of a forum! ) mikeb (I think) had found a way to change
pupsaves without exiting the Puppy. I guess that what you are seeking is along those
lines. If he could do it with a pupsave, why not with a regular sfs?
The trick, if I remember correctly, was to be in the main puppy sfs (probably in urxvt)
when doing the change. He had various pupsaves in the form of pup_rw directories
neatly stored on /mnt/home. He would erase the current /initrd/pup_rw and copy another
one in its place. And vroom, he had another flavor of the Puppy at his fingertips.
I don't know if this helps, but there you have it!
Bye for now / À+
musher0
_________________ musher0
~~~~~~~~~~
"You want it darker? We kill the flame." (L. Cohen)
|
Back to top
|
|
 |
Argolance

Joined: 06 Jan 2008 Posts: 3822 Location: PORT-BRILLET (Mayenne - France)
|
Posted: Sat 22 Aug 2015, 06:26 Post subject:
|
|
Quote: | I find you courageous to change the devx file "in vivo". I know that I wouldn't risk it! Smile
If it works, bravo! |
Je n'y suis pour rien: tout le mérite en revient à Puppy et son génial système de fichiers à couches!
I updated my post above to make my question more understandable.
No answer: silly/untoward question?
Cordialement.
_________________
Puppy Search
|
Back to top
|
|
 |
Argolance

Joined: 06 Jan 2008 Posts: 3822 Location: PORT-BRILLET (Mayenne - France)
|
Posted: Sat 22 Aug 2015, 14:05 Post subject:
|
|
Hello,
Quote: | No answer: silly/untoward question? |
Note: the suggestion above is about filemount and has nothing to do here with SFS_load.
Cordialement.
_________________
Puppy Search
|
Back to top
|
|
 |
musher0
Joined: 04 Jan 2009 Posts: 15041 Location: Gatineau (Qc), Canada
|
Posted: Sat 22 Aug 2015, 19:15 Post subject:
|
|
Ahem. That statement is illogical: the file system in the sfs file has to be mounted to
be of any benefit to the user.
Without filemount, no sfs. Oh, the sfs will exist, but as I said, it won't be of any benefit.
_________________ musher0
~~~~~~~~~~
"You want it darker? We kill the flame." (L. Cohen)
|
Back to top
|
|
 |
Argolance

Joined: 06 Jan 2008 Posts: 3822 Location: PORT-BRILLET (Mayenne - France)
|
Posted: Sun 23 Aug 2015, 05:33 Post subject:
|
|
Quote: | Suggestion: the button "Install SFS" [of filemount] should be labeled "Un/Install SFS" because user can uninstall/unload any SFS file this way too, |
_________________
Puppy Search
|
Back to top
|
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|