Autoloading of Modules, the Debian way.

Brett generica at email.com
Wed Mar 7 14:31:00 PST 2001


Why would you do such a thing ?

It really puzzles me as to why people bother modularising things that they
plan to load at boot.  Why not just build it in.  Modules are best suited
for things which are only used occasionally... like iso9660 fs support, or
perhaps smbfs.

Do you have a real reason for doing this ?

	/ Brett

On Wed, 7 Mar 2001 arthur at linuxbox.nu wrote:
>
> 
> Debian has a file called /etc/modules.  I borrowed from their code to make
> a quick and dirty hack of autoloading of modules at boot without kerneld
> or kmod.  This works for me:
> 
> (cat modules; echo) | # make sure there is a LF at the end
> while read /etc/module args
> do
>         case "$module" in
>                 \#*|"") continue ;;
>         esac
>         modprobe $module $args
> done
> 
> The case is for stripping comments.  I am calling it /etc/init.d/modprobe.
> ALl modules to load at boot are in /etc/modules
> 
> Arthur H. Johnson II
> Systems Engineer
> The Linux Box
> arthur at linuxbox.nu
> http://www.linuxbox.nu
> 
> 
> 


-- 
Unsubscribe: send email to lfs-discuss-request at linuxfromscratch.org
and put unsubscribe in the subject header of the message




More information about the lfs-dev mailing list