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

Re: [debian-knoppix] How to run a script at bootup?

On Tue, Aug 16, 2005 at 01:50:12PM +0200, Achim Unger wrote:
> Hallo,
> > On Mon, Aug 15, 2005 at 10:59:18PM -0500, Larry Alkoff wrote:
> > > I have a little rc.local script that should be run when Knoppix
> > > boots up  to start the network, prepare daemons for nfs, run my
> > > firewall etc.
> > > 
> > > It should run near the end of the boot process.  Where can I put
> > > this so  it will be sure to run?
> > 
> > I like easy questions. :-)
> > 
> > Just put your shell script right on the uncompressed part of the CD
> > inside the KNOPPIX directory and name it "knoppix.sh", so it will
> > automatically run at the end of knoppix-autoconfig. Then create the
> > new bootable ISO containing that file (the instructions on
> > http://www.knoppix.net/wiki/Knoppix_Remastering_Howto#Live_CD_ISO may
> > be helpful for this task).
> > 
> > Prior to remastering, you can test your "knoppix.sh" script on a USB
> > memory stick by entering
> > 
> > knoppix myconfig=/dev/sda1
> > 
> > at the boot: prompt (if your USB stick is /dev/sda1).
> Is it possible to put knoppix.sh on the top level of the CD by default?
> If using a DVD+RW, the file knoppix.sh could be added with:
>  growisofs -R -J -M /dev/sr0  /path_to_knoppix.sh/knoppix.sh 
> Or maybe it would be more compatible to search the top level AND the
> KNOPPIX directory?

It is searched only in the KNOPPIX directory by default, but a
workaround would be that you add a "toplevel" knoppix.sh into the
KNOPPIX directory which then searches for other locations of scripts,

You could maybe use graft-points to add files to other directories other
than the root directory of the DVD.

> This file could only be appended to the top level. Maybe I just do not
> know how to put it in KNOPPIX (without remastering of course). Does
> anybody know?

You could say -graft-points and then

Actually, I'm using the graft-points feature to create the files in the
KNOPPIX2 image on the DVD edition of Knoppix. I noticed even k3b uses
graft-points automatically.

With kind regards
-Klaus Knopper

Reply to: