LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   Kernel 2.6 using rc.modules-2.4 in Slack 11.0? (https://www.linuxquestions.org/questions/slackware-14/kernel-2-6-using-rc-modules-2-4-in-slack-11-0-a-553178/)

thethinker 05-11-2007 12:51 PM

Kernel 2.6 using rc.modules-2.4 in Slack 11.0?
 
Hey Everyone,
In my continuing battle to make sound work in kernel 2.6, I found a strange thing I figured I would ask about. It looks like my 2.6 kernel (which runs in all ways very nicely except it can't find my sound card...let's not address that I've got a whole other thread for it...:-() is using the module configuration file from my old kernel (2.4.33.3). There is a link from /etc/rc.d/rc.modules -> etc/rc.d/rc.modules-2.4.33.3, and there is no rc.modules-2.6.18. When slack stars up it runs this file (rc.modules) and no errors, just gets "no new modules dependencies found". Is this something strange or does the 2.6 kernel just deal with modules differently than the 2.4 kernel?

Thanks.

Alien Bob 05-11-2007 01:09 PM

You should create a rc.modules file for your 2.6 kernel. The Slackware 2.6.17.13 kernel package installs a file /etc/rc.d/rc.modules-2.6.17.13 but when you compile your own kernel, a rc.modules file for that kernel is your responsibility.
If you want to run 2.6 kernels exclusively, the easiest option is to create a new file /etc/rc.d/rc.modules (i.e. deleting the symlink) and use the content of the Slackware original rc.modules-2.6.17.13 for that file.

That will not get you a working sound though, since sound modules are loaded either by rc.alsa or by UDEV.

Eric

Alien_Hominid 05-11-2007 01:12 PM

rc.modules is simply a file, where all available modules are listed.
you can uncomment and the module will be automatically loaded during boot up.
there is no difference what kernel you have installed, because modules will be loaded from the old file, unless you make a new one. It's better to compile support directly into the kernel.

north49er 05-11-2007 01:43 PM

I have been unable to get sound working properly either (gone through all alsamixer, etc.etc.), and even complied the latest alsa. I decided to give the 2.6.17.13 kernel another try, and the same problems persist, but 2.4 kernel works perfectly. After reading up on hotplug/udev, I looked up what's mounted. udev is not mounted, but usbfs is. Both rc.hotplug and rc.udev are enabled. I've tried making one of the two unexecutable, but I get the same behavior in sound. I'd like to hear from those knowledgeable in this area explain if these modules could be affecting sound.

PeterETV 05-11-2007 01:46 PM

If you are using the default 2.6 kernel from the installation-CD, you're going to need the modules. 2.6.17.13 modules are on the second disk (/extra), and the 2.6.18-modules are on the fourth (/testing). Just installpkg these.
After this you'll find the modules in /etc/rc.d, and then you can remove the current rc.modules (which is just a symlink to the 2.4-modules in your case), and make a new symlink to the modules you want.
That's : ln -s rc.modules-2.6-whatever rc.modules, if I'm correct.

lali.p 05-11-2007 02:22 PM

well just a reminder that whenever you upgrade a kernel say from 2.4 to 2.6 you
need to run alsaconf and thereafter you can do 'alsamixer'


If you are unable to enable sound then may be it's beacuse you don't have sound support
neither 'gard-wired' nor have you built a module supporting your sound card .

just do lspci | grep audio to get knowledge about your sound card

:P

thethinker 05-11-2007 02:48 PM

lali.b2:

alsaconf freezes my machine (which it doesn't do on kernel 2.4). lspci doesn't show the sound card, but cat /proc/asound/cards does. The module is loaded correctly, I can see it through lsmod.

PeterETV:

I downloaded and configured my own kernel from kernel.org; will that have the modules in it? I did make, make modules, make modules_install.

PeterETV 05-11-2007 02:59 PM

Well, since I haven't compiled a custom or downloaded kernel myself yet (haven't found a need yet, have ACPI on my laptop fully working with a stock Slackware-kernel, so I won't have to either for the time being), I can't comment on that....
My guess would be that the modules should end up in /etc/rc.d/, which means that you should check if rc.modules points to the right modules...
Did you check the sticky about Kernel Configuration yet?

Alien_Hominid 05-11-2007 03:38 PM

You can use config file from Slackware kernel and build the kernel yourself.

allend 05-12-2007 08:14 AM

Quote:

there is no difference what kernel you have installed, because modules will be loaded from the old file, unless you make a new one.
This is not correct. From /etc/rc.d/rc.S
Quote:

# This loads any kernel modules that are needed. These might be required to
# use your ethernet card, sound card, or other optional hardware.
# Priority is given first to a script named "rc.modules.local", then
# to "rc.modules-$FULL_KERNEL_VERSION", and finally to the plain "rc.modules".
# Note that if /etc/rc.d/rc.modules.local is found, then that will be the ONLY
# rc.modules script the machine will run, so make sure it has everything in
# it that you need.
What happens is as your system boots it will look for a /etc/rc.d/rc.modules.local file (usually not present) then a /etc/rc.d/rc.modules-`uname-r` file.
These modules are expected to be in a directory tree under /lib/modules/`uname-r`.
The symlink /etc/rc.d/rc.modules has no effect during boot, but should be maintained as a link to rc.modules-`uname-r` as a matter of convenience. (It is easier to type pico rc.modules rather than the full name)


All times are GMT -5. The time now is 03:27 AM.