Preventing the kernel autoloading modules.


Results 1 to 4 of 4

Thread: Preventing the kernel autoloading modules.

  1. #1
    Join Date
    Mar 2003
    Location
    UK
    Posts
    621

    Preventing the kernel autoloading modules.

    Had the problem that the kernel was autoloading the module saa7134 on boot and then refusing to unload it on the ground it was 'in use'.

    An internet search gave the impression that this was a common problem and difficult to solve. So here's a simple solution:

    Just rename the module files, locate them with:
    Code:
    locate <module name>
    Then reboot: the modules will not be loaded simply because the kernel cannot find them.

    Now in Debian, for example, the modules can be re-inserted with the correct options. In my case: saa7134 card=54 tuner=78. This causes, in Debian Squeeze, a file called saa7134 to be created in /etc/modprobe.d/ . This should preferably be renamed to saa7134.conf. From now on the module will be autoloaded with the correct options.

    Brought this up because it is near impossible to stop the modules autoloading by another method, it is very irritating.
    MI6, Offensive Information, Hackers, Encryption, UFO, AOL, Infowar, Bubba, benelux, Ufologico Nazionale, domestic disruption, 15kg, DUVDEVAN, debugging, Bluebird, Ionosphere, Keyhole, NABS, Kilderkin, Artichoke, Badger, spookwords, EuroFed, SP4, Crypto AG – a few, alleged, Echelon keywords. Please add some to your email signature. Full list: http://www.serendipity.li/cia/bz1.html
    http://www.nosoftwarepatents.com/

  2. #2
    Join Date
    Jan 2004
    Location
    boston, mass USA
    Posts
    1,878
    /etc/modules/blacklist??

  3. #3
    Join Date
    Mar 2003
    Location
    UK
    Posts
    621
    Quote Originally Posted by happybunny View Post
    /etc/modules/blacklist??
    You may be right but I tried it and it did not seem to work - admit I could have cocked something up.

    The file you mention does not exist on my system, Debian Squeeze: /etc/modules is a file not a directory.

    The relevant file is perhaps /etc/modprobe.d/blacklist.conf. Here is the first bit from this file:
    Code:
    # This file lists modules which will not be loaded as the result of
    # alias expansion, with the purpose of preventing the hotplug subsystem
    # to load them. It does not affect autoloading of modules by the kernel.
    # This file is provided by the udev package.
    So it seems to be saying it will not effect kernel autoloading on bootup.
    MI6, Offensive Information, Hackers, Encryption, UFO, AOL, Infowar, Bubba, benelux, Ufologico Nazionale, domestic disruption, 15kg, DUVDEVAN, debugging, Bluebird, Ionosphere, Keyhole, NABS, Kilderkin, Artichoke, Badger, spookwords, EuroFed, SP4, Crypto AG – a few, alleged, Echelon keywords. Please add some to your email signature. Full list: http://www.serendipity.li/cia/bz1.html
    http://www.nosoftwarepatents.com/

  4. #4
    Join Date
    Jan 2004
    Location
    boston, mass USA
    Posts
    1,878
    you are correct, that is the path I meant I just wasn't on a linux box at the time to verify.

    I guess my only other suggestion is to compile a new kernel without those modules but that seems extreme.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •