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 25 Jul 2014, 23:11
All times are UTC - 4
 Forum index » House Training » Beginners Help ( Start Here)
Symlinks aren't saved; original files are restored
Moderators: Flash, Ian, JohnMurga
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 1 [8 Posts]  
Author Message
woodymnt

Joined: 23 Apr 2013
Posts: 8

PostPosted: Tue 14 May 2013, 20:41    Post subject:  Symlinks aren't saved; original files are restored  

Hi. I'm having trouble creating symlinks. Say, I install Gimp. The tray indicator of how much space I have in my pupsave goes from 265 to 175M. So I see the bulk of the installation went into /usr/lib/Gimp and /usr/share/Gimp. First I copy those folders to a partition on my usb plug that is formatted to ext2. Then I delete the two Gimp folders from /usr/lib and /usr/share.. Then I drag the folders I copied to those places and create links to them. Everything works fine, but when I reboot saving the pupsave I don't regain any space. The two Gimp folders are back intact in place of the symlinks.

EDIT: It would make much more sense to have Gimp and its deps in an SFS file that gets loaded at startup. -Thanks
Back to top
View user's profile Send private message 
`f00


Joined: 06 Nov 2008
Posts: 809
Location: the Western Reserve

PostPosted: Wed 15 May 2013, 11:34    Post subject:
Subject description: ..
 

Hi woodymnt

Did you install gimp from a dotpet? Make a backup of ~/.packages/<gimp-pkg>.files to check ppm's uninstall manually (possibly after a reboot if needed). Uninstall via ppm (Puppy Package Manager).

Yep, sfses work well for keeping savefile slim'n'healthy Smile

sszindian reports a gimp sfs that works nice in latest precise, others should be available if that's not your version ~or~ you can roll your own with dir2sfs..

Hope that helps & Welcome to the kennels Very Happy
Back to top
View user's profile Send private message 
woodymnt

Joined: 23 Apr 2013
Posts: 8

PostPosted: Fri 17 May 2013, 21:14    Post subject:  

Thanks f00. I use Lucid and found a great Gimp sfs for it here.

So thats good but I still have the same problem: When I try to make a symlink to keep the pupsave to a minimum, the target is always back where it was after save and reboot. I'm formatted to ext2, and the symlink is on the same partition. It must be something stupid I'm doing wrong but I can't figure out what it is.

I copy what I want to symlink to its destination outside of the pupsave, then I delete the original contents from the filesystem and replace that with a symbolic link to the destination. After save and reboot the contents are back in full, with the symlink still there inside the folder that reinstated itself.
Back to top
View user's profile Send private message 
`f00


Joined: 06 Nov 2008
Posts: 809
Location: the Western Reserve

PostPosted: Sat 18 May 2013, 19:54    Post subject:
Subject description: the other other hand
 

You shouldn't need symlink(s) for an add-on sfs in /mnt/home - it takes up no space (in your savefile) other than whatever personal config you've done to gimp. An add-on sfs does show as part of the filesystem when it's mounted via bootmanager or an sfs utility like sfs_load (on-the-fly).

If you want to examine what's really in your savefile (and perhaps modify the savefile directly), use the bootcode "puppy pfix=ram" for a pristine environment (savefile and extra sfses not loaded). Navigate to /mnt/home (which is itself a symlink to your home partition) and click-mount your savefile in a rox window.. It's easy enough to keep track of where you are since the path has some '+' marks in it. Don't forget to click-unmount the savefile when you're done. Reboot->NoSave or make a new small savefile (kind of handy to have more than one if you want to keep some basic settings or do backup work).

Yeah, it took me awhile to get the gist of how things work (sfs, un/install and so on) - so as long as you have backup you should be fine to play about.
Back to top
View user's profile Send private message 
Bruce B


Joined: 18 May 2005
Posts: 11080
Location: The Peoples Republic of California

PostPosted: Sat 18 May 2013, 23:58    Post subject:  

I don't yet understand why the problem. I've attached a pic showing the commands I used to make and display a test. It worked just as I expected.

The colors will show a good symlink and a broken one, where the red shows a missing source file for the link.

If you want to run the commands I'd want to know if it worked as it worked for me or if something else happened. If so, what?

Also consider some symlinks are relative and others absolute. The example shows relative links.

An absolute (path) link is different and whould require me to give the absolute path.

ln -s /mnt/sdw2/deletefile.txt

with the symlink named deleteme.txt being made in the current directory.

~
links.jpg
 Description   
 Filesize   100.24 KB
 Viewed   235 Time(s)

links.jpg


_________________
New! Puppy Linux Links Page
Back to top
View user's profile Send private message 
woodymnt

Joined: 23 Apr 2013
Posts: 8

PostPosted: Mon 31 Mar 2014, 08:05    Post subject:  

Bumping this because I found a workaround and failed to post it here. I solved the problem by mounting the pupsave from another puppy and deleting whatever I wanted to link from it that way. To do this type:
Code:
mount /mnt/sdxX/(name of)pup_save.2fs /mnt/data -o loop

Thanks Bruce for trying to help. I was too embarrassed to get you clarify what you wanted me to do. Cool

Last edited by woodymnt on Mon 31 Mar 2014, 08:43; edited 1 time in total
Back to top
View user's profile Send private message 
mikeb


Joined: 23 Nov 2006
Posts: 8029

PostPosted: Mon 31 Mar 2014, 08:22    Post subject:  

snapmergepuppy does not handle this properly ..thought you might want some insight

mike
Back to top
View user's profile Send private message 
SFR


Joined: 26 Oct 2011
Posts: 1039

PostPosted: Mon 31 Mar 2014, 10:03    Post subject:  

The problem is that after moving the directory outside of the savefile and symlinking it back, we have a situation where the directory is still in the savefile (/initrd/pup_ro1/), but in tmpfs is symlink.
So, during saving the session, cp (used in snapmergepuppy) will refuse to overwrite a directory with a symlink.
BTW, perhaps it's possible, but I haven't found a way to force cp to overwrite a dir with a symlink...

A simple workaround could be:
1. Move the directory outside of the savefile.
2. Save the session (this will delete the dir from the savefile).
3. Then create the symlink in place of moved directory.
4. And save the session again.

Greetings!

_________________
[O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource
Omnia mea mecum porto.
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 1 of 1 [8 Posts]  
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » House Training » Beginners Help ( Start Here)
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.0646s ][ Queries: 12 (0.0037s) ][ GZIP on ]