Can "/etc/rc.conf" be replaced with a symlink?

Loren M. Lang lorenl at alzatex.com
Tue Mar 1 21:22:31 PST 2005


On Mon, Feb 28, 2005 at 07:55:18AM -0500, Clay wrote:
> I realized what the problem mostly likely was after submitting the question. 
> I do believe that the mount point where I am wanting to have rc.conf located 
> is not yet available when the file is read.  Is there a way to have this FS 
> mounted prior to rc.conf being read?  Could I maybe place this mount point 
> above the root in fstab?  I will give it try when I have time later today.

No.  The process FreeBSD uses to boot is as follows:

1. Load kernel from disk or other media
2. Kernel initializes various hardware and subsystems.
3. Kernel mounts root file system.
4. Kernel invoked init
5. Init runs /etc/rc and waits for it to complete
6. /etc/rc reads /etc/rc.conf
7. /etc/rc runs various scripts in /etc/rc.d in a specified order
8. Various scripts run including /etc/rc.d/mountcritlocal
9. Init loads gettys specified in /etc/ttys and goes into it's main loop

The order in fstab doesn't matter, the kernel only knows enough to mount
the root fs, and the scripts in /etc/rc.d mount all the other
filesystems, but by then, rc.conf has already been read or attempted to
be read.  You could hack /etc/rc to mount another fs, but I would
strongly recommend against it.

> 
> Thanks,
> -Clay 
> 
> 
> _______________________________________________
> freebsd-questions at freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to "freebsd-questions-unsubscribe at freebsd.org"

-- 
I sense much NT in you.
NT leads to Bluescreen.
Bluescreen leads to downtime.
Downtime leads to suffering.
NT is the path to the darkside.
Powerful Unix is.

Public Key: ftp://ftp.tallye.com/pub/lorenl_pubkey.asc
Fingerprint: CEE1 AAE2 F66C 59B5 34CA  C415 6D35 E847 0118 A3D2
 


More information about the freebsd-questions mailing list