Tiny Core Linux

Tiny Core Base => TCB Talk => Topic started by: mgseaborn on November 05, 2012, 06:19:28 PM

Title: How does mydata.tgz get loaded on boot
Post by: mgseaborn on November 05, 2012, 06:19:28 PM
The file architecture diagram suggests that /home/tc/ gets loaded from tce/mydata.tgz so I placed mydata.tgz in to the tce directory of my tftp boot server, from where I'm PXE booting TCL.  However, after TCL boots the tc home directory does not contain the contents of mydata.tgz.

Do I need to specify some boot option?

Thanks for your help.
Title: Re: How does mydata.tgz get loaded on boot
Post by: gerald_clark on November 05, 2012, 07:47:07 PM
There is a wiki article on persistence for PXE booting.
Title: Re: How does mydata.tgz get loaded on boot
Post by: mgseaborn on November 07, 2012, 01:02:19 PM
the persistence articles in the wiki discuss loading extensions via nfs.  Is it possible to load mydata.tgz via tfpt?  Also, is there an example that shows how to load an extension via tfpt (or from a Windows Share)?
Title: Re: How does mydata.tgz get loaded on boot
Post by: curaga on November 07, 2012, 02:24:10 PM
No built-in support for loading it via tftp, but you can add it to bootlocal in two lines.

Download it to /tmp, and then extract with tar.
Title: Re: How does mydata.tgz get loaded on boot
Post by: tinypoodle on November 07, 2012, 02:56:33 PM
Search wiki for dynamic remastering for extensions.

As a quick hack I would sometimes tftp -g mydata.tgz after boot, untar it as root over / and logout/login.
Title: Re: How does mydata.tgz get loaded on boot
Post by: gerald_clark on November 07, 2012, 04:16:00 PM
As the wiki article states, with the tce=nfs boot option, extensions and mydata.tgz get saved and loaded just as if they were on a hard drive.  There is nothing special to do.
Title: Re: How does mydata.tgz get loaded on boot
Post by: mgseaborn on November 07, 2012, 06:26:23 PM
As the wiki article states, with the tce=nfs boot option, extensions and mydata.tgz get saved and loaded just as if they were on a hard drive.  There is nothing special to do.

I found the solution by remastering tinycore.gz.  Thanks.
Title: Re: How does mydata.tgz get loaded on boot
Post by: tinypoodle on November 07, 2012, 07:38:36 PM
As the wiki article states, with the tce=nfs boot option, extensions and mydata.tgz get saved and loaded just as if they were on a hard drive.  There is nothing special to do.

The way I understand that - feel free to correct or confirm me - with tce=nfs a permanent dependence on the server is created as opposed to a simple pxe boot which allows for disconnection from network just after booting.
Title: Re: How does mydata.tgz get loaded on boot
Post by: gerald_clark on November 07, 2012, 07:56:11 PM
That depends on whether the copy2fs.flg exists.
With copy2fs.flg, you should be able to umount /mnt/nfs after extensions are loaded and mydata.tgz is extracted.
Title: Re: How does mydata.tgz get loaded on boot
Post by: tinypoodle on November 07, 2012, 08:55:03 PM
Very good point, I didn't think that far...

OTOH, copy2fs could result in a memory footprint penalty, so it may depend on how much RAM is available and the size of extensions loaded.