HD Install :: Mounting /dev/hdaX at boot time...



If you had read my post you would see that I was already doing that... :D I added a script to /etc/init.d called it mountit.sh then contents:

#!/bin/bash
#Script to mount my partitions in fstab
echo "Mounting everything in /etc/fstab that should get mounted"
mount -a &

Then I made a link using the command:

ln -s /etc/init.d/mountit.sh /etc/rcS.d/S35mountit.sh

The S35 part deterimins when it will be run during startup, S meaning start up, 3 meaning runlevel 3, and I am not possitive about the 5 part but I assume that is part of what order in runlevel 3.

Since /home isn't read till after runlevel 5 is reached, and on other systems it seems that mounting init scripts are done in runlevel 3, I thouht that would be a good place to do it.

Quote (Wraithan @ July 31 2006,14:25)
If you had read my post you would see that I was already doing that... :D I added a script to /etc/init.d called it mountit.sh then contents:

My suggestion was to add a simple line to what was already there.   ???

The S in S35 says to run the script with a start argument i.e.

/etc/init.d/myscript start

A K in front K35 would call the script to kill the process

/etc/init.d/myscript stop

I was under the impression that the number was for order of operation.  If you look in rc6.d (shutdown/reboot init) you will see that something that starts with S99 will be stopped with K01 or something like that (that last ones to get stopped are usually the first ones that got started and the last things that got started are the first ones stopped).

Have you actually gotten this to work by putting it in the Single user mode init folder (rcS.d)?  I thought you should have it in the folder for the init number that you run at startup (the default init in the inittab file rc5.d)?  If it does not work try creating the link in the rc5.d directory.
???

It works great in the folder I specified above... though I am not in multiuser mode. I posted the exact stuff I did to make it work so that who ever searches this topic can find instructions on how to do it.

original here.