[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

persistence and custom kernel



>
> Home persistence does work, and performs very well, even better than disk
> installed OSs, because only the user documents and settings are written to
> disk, the rest is done in RAM memory.
> In an unmodified live system has the label 'home-rw', but we can modify
> the /etc/live.conf file assigning other values. Ex.
>
> home_persistence="santiago-rw"
>
> if it is a USB partition that works the same, with the partition label; only
> is necessary to wait for the operating system mounting the usb devices,
> Modify the /etc/live.conf with:
>
> live-media-timeout=15 (not sure if is that variable?)
>

Is this modification after the lh_chroot stage?


> >
> > I would not need the persistence feature if I had enough knowledge to
> > include my own /etc/network/interfaces file and other things. I wish there
> > was some documentation about this...
>
> it's easy to include files creating an additional file of ext2 or ext3 type,
> or even a simple directory.
>
> example, create in the live-media-path a directory with any name and the
> extension ".dir"
>
> mkdir -p live/myfiles.dir
>
> mkdir -p live/myfiles.dir/etc/network/
> cp /etc/network/interfaces live/myfiles.dir/etc/network/
>
> or create a subdirectory for the hostname and include files for the live
> filesystem for that host,
> debian live will search for additional filesystems in the subdirectory
> corresponding to the live hostname
>
> mkdir -p live/myhostname
>
>   cd /tmp
> # the directory hostfiles will contain the filesystem structure
>   mkdir -p /tmp/hostfiles
>   mkdir -p //tmp/hostfiles/etc/network
>   cp /etc/network/interfaces  //tmp/hostfiles/etc/network
>   export COUNT=$[$(du -s hostfiles | awk '{ print $1 }' )*2+1000]
>   echo $COUNT
> # the hostfiles.et3 file will be included in the live filesystem
>   dd if=/dev/zero of=hostfiles.ext3 count=0 seek=$COUNT
>   mkfs.ext3 -F hostfiles.ext3
>   mkdir dir
>   mount -o loop hostfiles.ext3 dir
>   cp -a hostfiles/* dir
>   rm -Rf dir/lost+found
>   umount dir
>
> cp hostfiles.ext3 live/myhostname
>

I tried both ways:

I could see after booting the usb stick that the file hostfiles.ext3
is under live/myhostname but that is all... The actual
/etc/network/interfaces file in use by the live system is the default
and not the one within hostfiles.ext3. This also applies to
live/myfiles.dir

I guess a simple thing to do would be to include a script extracting
the file needed from hostfiles.ext3 and replace the
/etc/network/interfaces file. Is this the idea? or is debian-live
supposed to do this automatically?

I really appreciate your help, thanks!

Santiago



Reply to: