# Gentoo sources module loading

## JC99

Hello,

I was using vanilla sources but decided to switch to gentoo sources. One thing that is different is that when the computer boots up it says something like...

 *Quote:*   

> Loading Modules
> 
> scanning for pata ... loaded

 

It does that with maybe 50 modules but they move past the screen to fast to see them all. How do I turn some of them off so it doesn't load a bunch of modules I don't need?

Thanks

----------

## mvaterlaus

hi,

I assume that you use the genkernel along with gentoo sources. this is a very generic kernel which configures itself. if you do not want that behavior, you have to compile your kernel manually. have a look at the gentoo handbook [1] on how it's done. a good thing is also the kernel-seeds.org [2] page, which contains a howto and a minimal .config file to start with your own manually built kernel.

[1]http://www.gentoo.org/doc/en/handbook/handbook-x86.xml?part=1&chap=7#doc_chap3

[2]http://kernel-seeds.org/working.html

----------

## JC99

I don't know if this affects things but I recently setup my system using raid1. I used genkernel to create my kernel because it created an initramfs and my system won't boot without one. I used vanilla-sources.

In the past (before using raid1) I built my kernel manually using vanilla sources. I never used an initramfs and the following never occurred while loading...

 *Quote:*   

> Loading Modules
> 
> scanning for pata ... loaded
> 
> scanning for sata ... loaded
> ...

 

...so I assume the scanning and loading of modules is the result of my initramfs???

I have 2 questions

a) How do I configure what modules are loaded by initramfs. I don't need pata for example.

b) How do I create a initramfs manually without genkernel

Thanks

----------

## The Doctor

I believe that this is the Dracut you are looking for.

Although depending on why you need an initramfs you might want to consider other options. If you just need to mount /usr I believe that busybox now has a patch to do that without one and there are scripts to create a generic initramfs without a specific kernel dependence for the same purpose.

----------

## JC99

Thanks for that link, I'll read it over.

I don't need to mount /usr.

Since setting up raid1 my computer won't boot without an initramfs. I would like to be able to boot up without one. Does raid1 require an initramfs?

----------

## JC99

I tried creating a vanilla-sources kernel without initramfs but on boot up it says...

 *Quote:*   

> kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(0,0)

 

...I believe it is looking for something like sda but because I am using Raid1 it has to deal with md124 which it doesn't recognize.

Anyone know how to get this working?

Thanks

----------

## The Doctor

Well I don't know anything about RAID, but with a quick google search I found this http://www.gentoo.org/doc/en/gentoo-x86+raid+lvm2-quickinstall.xml and it talks about passing the domdadm option to the kernel on boot if you do not have an initramfs.

Although I would also make sure that you built your root file system into the kernel and not as a module.

----------

## JC99

I tried using dracut but my system would freeze up on boot so I don't think that is going to work out. 

I would like to get my system up and running without an initramfs image if possible

----------

## jago25_98

Ah, a relatively  new thread.

Instead of recompiling a kernel without modules isn't there a way to speed up modules on boot? (for people who prefer this or just for the sake of wanting to know how) 

- possibly by manually specifying what modules are needed or by looking at what was loaded on the last boot and using that, or by manually passing a boot parameter via grub (I think this is what initrd is for)

http://www.dark.ca/2009/06/10/initrd-modules-and-tools/

http://www.linuxquestions.org/questions/linux-newbie-8/scanning-for-unwanted-modules-at-boot-471150/

----------

