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 Wed 16 Apr 2014, 15:20
All times are UTC - 4
 Forum index » House Training » Users ( For the regulars )
rc.local doesn't keep changes!
Moderators: Flash, Ian, JohnMurga
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 1 [5 Posts]  
Author Message
sunburnt


Joined: 08 Jun 2005
Posts: 4979
Location: Arizona, U.S.A.

PostPosted: Sun 15 Jan 2006, 18:55    Post subject:  rc.local doesn't keep changes!  

I added a few lines to the rc.local file to run another script not on the image.gz file.

if [ -f "/mnt/home/add-local" ]; then
. /mnt/home/add-local
fi

If made part of all Puppies, additions could be made to the bootup without having to make a new image.gz file every time.

I made a new image.gz & then gunzipped it & checked it's contense, all was good.
Bootup didn't run the "off - image.gz" file: add-local.
Checking the /etc/rc.d/rc.local file showed that the added lines weren't there!
I'm really confused how the rc.local file got changed back to it's original state.
Back to top
View user's profile Send private message 
MU


Joined: 24 Aug 2005
Posts: 13642
Location: Karlsruhe, Germany

PostPosted: Sun 15 Jan 2006, 19:10    Post subject:  

/etc/rc.d/rc.local0 is used for user-entries.
You won't even have to build a new image.gz.
Mark
Back to top
View user's profile Send private message Visit poster's website 
Pizzasgood


Joined: 04 May 2005
Posts: 6270
Location: Knoxville, TN, USA

PostPosted: Sun 15 Jan 2006, 19:25    Post subject:  

Actually, it depends (I think).
You should edit rc.local for an individual installation.
If you remaster the image.gz, you need to do the editing to rc.local0.

rc.local is definately persistant when you simply edit it, but from your post it looks like it isn't when you remaster it. In Puppy, if there is a file with a 0 at the end of it, that is what you edit before remastering. Like root0.

_________________
Between depriving a man of one hour from his life and depriving him of his life there exists only a difference of degree. --Muad'Dib

Back to top
View user's profile Send private message Visit poster's website 
kethd

Joined: 20 Oct 2005
Posts: 451
Location: Boston MA USA

PostPosted: Sun 15 Jan 2006, 22:55    Post subject:  

I like what you are trying to do -- I have been thinking/working along the same lines -- let us know what you figure out!

But I am confused about the specific construct -- are you sure it is legal? I thought I read that way of "including" scripts was limited to the current sub-directory, or something screwy like that? So, I thought maybe a script would have to be copied before it could be include-processed, which would maybe be impossible if you were currently within a read-only filesystem...
Back to top
View user's profile Send private message 
sunburnt


Joined: 08 Jun 2005
Posts: 4979
Location: Arizona, U.S.A.

PostPosted: Mon 16 Jan 2006, 06:19    Post subject:  

I think Pizzasgood is right;
rc.local is edited directly, NOT in the image.gz file
rc.local0 is edited in the image.gz file (I think, I'll check to be sure)

Directly editing rc.local0 DID NOT keep the changes at boot.

So... rc.local seems to come from the pup001 file, & rc.local0 seems to come from the image.gz file.

kethd; the file in: /mnt/home ran just as my code is, just use a full path to it (of course).

Thanks guys, I've been struggling with this.
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 1 of 1 [5 Posts]  
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » House Training » Users ( For the regulars )
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.0481s ][ Queries: 12 (0.0097s) ][ GZIP on ]