noob question on init scripts

Matt Galvin matt.t.galvin at gmail.com
Wed Feb 23 15:44:43 UTC 2005


One other way you could try doing this, which is very easy, is go to
the Gnome Prefs menu and select the "Sessions" prefs. Select the
"Startup Programs" tab and "Add" your command there. Do this
<b>only</b> if your command does not require being run at boot time.
This will run your command when you log into Gnome, i.e., when the
Gnome "session" starts.

Althought this is not an "init" script, it sort of does close to the
same thing. Again, only do this if your command does not "need" to run
at boot time. Also, doing it this way means that your command will not
get run until you log into gnome.

I only mention this, b/c as a noob, it's easier to do.

Hope this helps,

Matt


On Wed, 23 Feb 2005 16:25:49 +1300, Jim Cheetham <jim at egressive.com> wrote:
> On Wed, 2005-02-23 at 11:18 +0800, Senectus . wrote:
> > I have a command I want to run every time I start the PC, would
> > putting it in the init.d directory be the best practice way of doing
> > it?
> 
> If it's a "system" task, then possibly, yes - there's a load of overhead
> to doing it correctly, just putting a file in there will not result in
> it being run.
> 
> As an alternative, you could reference your command in crontab, using
> the @reboot time specification instead. That might be more appropriate.
> See 'man 5 crontab'
> 
> --
> -jim cheetham = jim at egressive dot com
> www.egressive.com, www.effusiongroup.com
> 
> 
> --
> ubuntu-users mailing list
> ubuntu-users at lists.ubuntu.com
> http://lists.ubuntu.com/mailman/listinfo/ubuntu-users
>




More information about the ubuntu-users mailing list