Find the answer to your Linux question:
Results 1 to 6 of 6
i need some help on how can i autorun a program when my linux box boots... let say like a simple command "/usr/local/bin/./program" thanks......
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Aug 2006
    Posts
    11

    program autorun on boot


    i need some help on how can i autorun a program when my linux box boots...

    let say like a simple command "/usr/local/bin/./program"

    thanks...


  2. #2
    Linux Guru sdousley's Avatar
    Join Date
    Feb 2004
    Posts
    1,790
    is this at boot, or on login to something like KDE? If it's something like logon to KDE, then you could put a script in /home/user/.kde/Autostart (i think it is). Then when you log into KDE, it will run through all the scripts in that folder. if it's at boot, you will be best off writing an init script for it. Unless it has some setting within the program to start it on boot.
    "I am not an alcoholic, alcoholics go to meetings"
    Registered Linux user = #372327

  3. #3
    Just Joined!
    Join Date
    Aug 2006
    Posts
    11
    it's just want a plain program...no more settings... and it's upon on boot not on kde....

    let's say i need to run /root/foo/./proggy upon boot which will just run in the background

    but ./proggy needs the file proggy.cfg which is inside /root/foo/

    ex.
    root@localhost#
    logs/
    README
    proggy*
    proggy.cfg

    thank you very much for the quick reply


  4. #4
    Linux Guru sdousley's Avatar
    Join Date
    Feb 2004
    Posts
    1,790
    OK, what i *think* you can do for this is put the program executable in rc.conf (somewhere in the /etc directory)

    Just put an entry in there for:

    Code:
    /root/foo/proggy
    note there's no need for the ./ in the path, since you're explicitly telling it where the executable is.

    The reason you will run "./proggy" in the /root/foo directory is simply because "/root/foo" isn't in the PATH environment variable.
    "I am not an alcoholic, alcoholics go to meetings"
    Registered Linux user = #372327

  5. #5
    Just Joined!
    Join Date
    Aug 2006
    Posts
    11
    hi there,

    i can't find my rc.conf... is there any way or another way....?

    thanks again


  6. #6
    Just Joined!
    Join Date
    Aug 2006
    Posts
    11
    anyone here......

    thanks in advance


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •