Modifying / replacing a kernel module
I recently created a thread asking for input on how to increase the number of loop devices allowed by the kernel. I ended up find a solution after many hours of trolling forums and newgroups. The solution is to unload the "loop.ko" module (/sbin/./rmmod /lib/modules/2.6.9-11.ELsmp/kernel/drivers/block/loop.ko) and then reloading it with an additional "max_loop=255" parameter (/sbin/./insmod /lib/modules/2.6.9-11.ELsmp/kernel/drivers/block/loop.ko max_loop=255). This works perfectly, even the extra loop devices spawn in /dev. The problem is that everything reverts on reboot. After a reboot, it's back to only allowing 8 loop devices (instead of the 255 I changed it to).
Does anyone know a way that I can modify the loop.ko module, replace the loop.ko module, or add these commands to a startup script to make sure that I have access to all 255 loop devices on the next boot? |
Quote:
Code:
#include <asm/uaccess.h> by the newly compiled one. Or: create a startup skript like (I don't know the exact syntax of the insmod/rmmod cmds in kernel 2.6.x): Code:
case "$1" in -bruce |
All times are GMT -5. The time now is 03:07 PM. |