Fedora 12 – How can we run one script when system startup?

Open one xterm or console.

Use command cd /etc/init.d/ .

You are now on /etc/init.d/ directory.

Create a file named my_filename.

Add your script to this file with the following lines at the top:

Enter this in the shell:

chkconfig --add my_filename

Use command chmod u+x my_filenameto make this script executable.

Type command:ntsysv

You will see a GUI.

Your startup script should now be in the list.

Use the space key to set your script.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.