Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Fri 22 Jun 2018, 05:53
All times are UTC - 4
 Forum index » Advanced Topics » Cutting edge
Savefolder without 'mount -o bind' - works
Moderators: Flash, Ian, JohnMurga
Post new topic   Reply to topic View previous topic :: View next topic
Page 3 of 9 [132 Posts]   Goto page: Previous 1, 2, 3, 4, 5, 6, 7, 8, 9 Next
Author Message
gyro

Joined: 28 Oct 2008
Posts: 1503
Location: Brisbane, Australia

PostPosted: Tue 07 Oct 2014, 12:36    Post subject: freememapplet_tray  

Here is a patch of 'freememapplet_tray.c':
Code:
--- freememapplet_tray.c.orig   2012-05-19 20:02:51.000000000 +1000
+++ freememapplet_tray.c   2014-10-08 01:56:41.045027125 +1000
@@ -68,7 +68,9 @@
     /*100517 always read free space in save file, not RAM space...*/
     /*if (pupmode!=6 && pupmode!=12) {fp = (FILE *)popen("df -m | grep ' /$' | tr -s ' ' | cut -f 2,4 -d ' '","r");}
     else {fp = (FILE *)popen("df -m | grep ' /initrd/pup_rw$' | tr -s ' ' | cut -f 2,4 -d ' '","r");}*/
-    if (pupmode==3) fp = (FILE *)popen("df -m | grep ' /initrd/pup_ro1$' | tr -s ' ' | cut -f 2,4 -d ' '","r");
+    if ((readlink("/initrd/pup_rw", meminfo, sizeof meminfo) != -1) || (readlink("/initrd/pup_ro1", meminfo, sizeof meminfo) != -1))
+        fp = (FILE *)popen("df -m | grep ' /initrd/mnt/dev_save$' | tr -s ' ' | cut -f 2,4 -d ' '","r");
+    else if (pupmode==3) fp = (FILE *)popen("df -m | grep ' /initrd/pup_ro1$' | tr -s ' ' | cut -f 2,4 -d ' '","r");
     else if (pupmode==7) fp = (FILE *)popen("df -m | grep ' /initrd/pup_ro1$' | tr -s ' ' | cut -f 2,4 -d ' '","r");
     else if (pupmode==13) fp = (FILE *)popen("df -m | grep ' /initrd/pup_ro1$' | tr -s ' ' | cut -f 2,4 -d ' '","r");
 // BK 110805 testing with PUPMODE=2, needs fix, there is no /dev/root...
Yes, same problem, assuming that it can get size information for 'pup_rw' from a mount entry.
I have added a working version of 'freememapplet_tray' to http://www.fishprogs.software/puppy/wheezy/ydrv_wheezy_3.5.2.11.sfs. This is the version I happened to be able to find source for.

So the list of required patches increases. But this symbolic link method has 1 advantage, they're all very specific to puppy.

gyro

Last edited by gyro on Sat 21 May 2016, 21:47; edited 1 time in total
Back to top
View user's profile Send private message 
mavrothal


Joined: 24 Aug 2009
Posts: 2971

PostPosted: Tue 07 Oct 2014, 13:53    Post subject: Re: freememapplet_tray  

gyro wrote:

I have added a working version of 'freememapplet_tray' to http://www.fishprogs.info/puppy/wheezy/ydrv_wheezy_3.5.2.11.sfs.

Also works in Precise so you may want to post it as a pet here.
BTW is it stripped? (is too big)

BK keeps sources in http://bkhome.org/sources/. Needs the usual user/pass. Has 7 versions of the applet in http://bkhome.org/sources/alphabetical/f/

_________________
== Here is how to solve your Linux problems fast ==
Back to top
View user's profile Send private message 
mavrothal


Joined: 24 Aug 2009
Posts: 2971

PostPosted: Wed 08 Oct 2014, 04:31    Post subject: Re: freememapplet_tray  

mavrothal wrote:
Also works in Precise so you may want to post it as a pet here.

Here is BK's freememapplet_tray-2.4 patched as above to v2.5

BTW I have also updated the precise-5.7.2 ISO with this.
freememapplet_tray-2.5.pet
Description  patched to recognise savefolder symlink
pet

 Download 
Filename  freememapplet_tray-2.5.pet 
Filesize  4.33 KB 
Downloaded  174 Time(s) 

_________________
== Here is how to solve your Linux problems fast ==
Back to top
View user's profile Send private message 
Bert


Joined: 30 Jun 2006
Posts: 1106

PostPosted: Wed 08 Oct 2014, 05:58    Post subject:  

A question from a simple soul: can I use the delta to update the precise 5.7.1 from within it, while it is running?

Or does this need to happen from another Puppy?
Apologies, I never used a delta before...

_________________


Back to top
View user's profile Send private message 
mavrothal


Joined: 24 Aug 2009
Posts: 2971

PostPosted: Wed 08 Oct 2014, 06:22    Post subject:  

Bert wrote:
A question from a simple soul: can I use the delta to update the precise 5.7.1 from within it, while it is running?

Or does this need to happen from another Puppy?
Apologies, I never used a delta before...

The delta will update the precise-5.7.1.iso (not the retro version), that you must have locally, to produce the precise-5.7.2.iso. So get the 5.7.1 iso and the delta and use "Xdelta file difference manager" to update the iso.
Then you can do a "manual frugal install" with the vmlinuz, initrd.gz and puppy_precise-5.7.2.sfs files from the new iso, either in a new folder or replacing the ones from 5.7.1 in your installation, or just burn and boot the iso.

_________________
== Here is how to solve your Linux problems fast ==
Back to top
View user's profile Send private message 
gyro

Joined: 28 Oct 2008
Posts: 1503
Location: Brisbane, Australia

PostPosted: Wed 08 Oct 2014, 06:44    Post subject: Re: freememapplet_tray  

mavrothal wrote:
Here is BK's freememapplet_tray-2.4 patched as above to v2.5
This also works in Dpup Wheezy. So I've replaced the 'freememapplet_tray' in http://www.fishprogs.software/puppy/wheezy/ydrv_wheezy_3.5.2.11.sfs with this one.

I've no idea why the other version was so large. Yes it was stripped.

gyro

Last edited by gyro on Sat 21 May 2016, 21:47; edited 1 time in total
Back to top
View user's profile Send private message 
backi

Joined: 27 Feb 2011
Posts: 1506
Location: GERMANY

PostPosted: Wed 08 Oct 2014, 07:35    Post subject:  

Tested 5.7.2 delta iso on USBstick but at shutdown did not create savefile .
Just shutdown *after asking to create a savefile ** without saving .
Back to top
View user's profile Send private message 
Bert


Joined: 30 Jun 2006
Posts: 1106

PostPosted: Wed 08 Oct 2014, 08:42    Post subject:  

mavrothal wrote:

The delta will update the precise-5.7.1.iso (not the retro version), that you must have locally, to produce the precise-5.7.2.iso. So get the 5.7.1 iso and the delta and use "Xdelta file difference manager" to update the iso.
Then you can do a "manual frugal install" with the vmlinuz, initrd.gz and puppy_precise-5.7.2.sfs files from the new iso, either in a new folder or replacing the ones from 5.7.1 in your installation, or just burn and boot the iso.


Perfect explanation... thank you mavrothal.

I updated an existing precise 5.7.1 to 5.7.2 successfully, writing from it now.

I am running Puppy from a usb stick with pupmode=12, my favourite way of using Puppy. Of course, this was lost during the update, because the initrd.gz
gets replaced by the new one. No problem: simply added "PUPMODE=12" again (with editinit).

So far, I did not succeed to change from save file to save folder.
As I did not find the "transform" script, I downloaded gyro's "savefile2dir", made executable and clicked it. Nothing happened.

Think I'll do a new installation tonight, to see if that makes a difference.
For now, I'm grateful having an up-to-date Precise!

Bert

_________________


Back to top
View user's profile Send private message 
mavrothal


Joined: 24 Aug 2009
Posts: 2971

PostPosted: Wed 08 Oct 2014, 08:50    Post subject:  

Bert wrote:

So far, I did not succeed to change from save file to save folder.
As I did not find the "transform" script, I downloaded gyro's "savefile2dir", made executable and clicked it. Nothing happened.

The savefile2dir script is in /root/my-applications/bin, so it's in the $PATH
You must call it from the terminal though like
Code:
savefile2dir /full/path/to/savefile/savefile.2fs
# ie something like
savefile2dir /mnt/home/Precise/precisesave.3fs

If you just click on it nothing happens Very Happy

@backi: see response here

_________________
== Here is how to solve your Linux problems fast ==
Back to top
View user's profile Send private message 
backi

Joined: 27 Feb 2011
Posts: 1506
Location: GERMANY

PostPosted: Wed 08 Oct 2014, 11:39    Post subject:  

Could make it working with ----savefile2dir /full/path/to/savefile/savefile.2fs

Want to ask ....can this be used in other Puppies too for example "Raring" ?

Whats necessary ?
Back to top
View user's profile Send private message 
mavrothal


Joined: 24 Aug 2009
Posts: 2971

PostPosted: Wed 08 Oct 2014, 11:51    Post subject:  

backi wrote:
Could make it working with ----savefile2dir /full/path/to/savefile/savefile.2fs

Want to ask ....can this be used in other Puppies too for example "Raring" ?

Whats necessary ?

If the patches can be applied cleanly it should work.
Keep in mind that for the init patch you must expand initrd.gz, patch it and re-compress it (must be a pet somewhere in the forum that does that if you do not know how).
You will also need the freememapplet_tray pet from above and of cource the sevefile2dir script

_________________
== Here is how to solve your Linux problems fast ==
Back to top
View user's profile Send private message 
Bert


Joined: 30 Jun 2006
Posts: 1106

PostPosted: Wed 08 Oct 2014, 12:13    Post subject:  

Success!

I now suddenly have 19GB to save to Very Happy
Thanks to mavrothal.

EDIT: this may be useful for others: the savefile2dir script needs some time to do its work. Nothing appears in the terminal for maybe a minute and then 2 lines appear, indicating process is finished.

Last edited by Bert on Wed 08 Oct 2014, 12:21; edited 1 time in total
Back to top
View user's profile Send private message 
backi

Joined: 27 Feb 2011
Posts: 1506
Location: GERMANY

PostPosted: Wed 08 Oct 2014, 12:19    Post subject:  

Thanks for your answer mavrothal

Where to place these patches ?
Back to top
View user's profile Send private message 
mavrothal


Joined: 24 Aug 2009
Posts: 2971

PostPosted: Wed 08 Oct 2014, 12:29    Post subject:  

Bert wrote:

I now suddenly have 19GB to save to Very Happy
Thanks to mavrothal.


Thanks, but this is gyro's work.
I just change the wrapping/packaging a bit Wink so hopefully will be tested by more people and possible issues will be identified and solved, so it can make it to woof-CE.

_________________
== Here is how to solve your Linux problems fast ==
Back to top
View user's profile Send private message 
mavrothal


Joined: 24 Aug 2009
Posts: 2971

PostPosted: Wed 08 Oct 2014, 12:35    Post subject:  

backi wrote:

Where to place these patches ?


Patches are applied to files.
You need to have devx loaded to patch.

_________________
== Here is how to solve your Linux problems fast ==
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 3 of 9 [132 Posts]   Goto page: Previous 1, 2, 3, 4, 5, 6, 7, 8, 9 Next
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Advanced Topics » Cutting edge
Jump to:  

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
[ Time: 0.0565s ][ Queries: 14 (0.0057s) ][ GZIP on ]