LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   running scrips on boot (https://www.linuxquestions.org/questions/linux-general-1/running-scrips-on-boot-436385/)

bdplays 04-18-2006 09:47 AM

running scrips on boot
 
Good Day,

I have 3 network shares that I mount into my file system. In the past, I have just retyped the mount commands if I ever had to reboot my Linux box. I realized that I was making much more work for myself than necessary so I wrote a small script that mounts my shares for me.

Now I would like to have the little mount script run automatically when the machine boots.

Q1: Where can I put my little mount script so it runs on boot?

Q2: Is there a better way to automatically mount my network shares on boot?

-Thanks for the help.

ethics 04-18-2006 10:29 AM

There is already a process dedicated to that, it's called fstab, search these forums, the file is /etc/fstab

take a look at it's format, pretty simple to work out, although nfs shares (i presume?) the path is nfs://ip if i remember right

distros differ sometimes in where the boot up scripts. but take a look in /etc/rc.d/rc<your run level>.d (atleast on fedora :) ) there are scripts there with S# and K# S is start the lower the number the high the priority, K is kill

bdplays 04-20-2006 03:10 PM

boot scripts
 
Cool. I wil give that a try. Appreciate the feedback.

anupamsr 08-01-2006 08:14 PM

please change the tag from scrips to script :) thanks


All times are GMT -5. The time now is 04:36 AM.