BusyBox Bug and Patch Tracking
BusyBox
  

Viewing Issue Simple Details Jump to Notes ] View Advanced ] Issue History ] Print ]
ID Category Severity Reproducibility Date Submitted Last Update
0001350 [BusyBox] Kernel Module Support major always 05-17-07 00:13 05-17-07 08:51
Reporter iggarpe View Status public  
Assigned To integrator
Priority normal Resolution unable to reproduce  
Status closed   Product Version svn
Summary 0001350: kernel module autoloading does not work (modprobe issue)
Description When the kernel wants to load a module it exeecutes /sbin/module (configurable v
Additional Information The obvious fix is to use the absolute paths to insmod and rmmod. Though it may seem a "dirty" solution in the sense that it forces the user to place those binaries in a fixed location, bear in mind that the "real" modprobe does it all by itself without calling external programs and thus gives no chance to the user to choose where to put the insmod/rmmod binaries anyway.

Probably the "good" solution is to emulate the "real" modprobe behaviour by making the module loading code part of libbb and using it both from insmod and from modprobe.
Attached Files

- Relationships

- Notes
(0002362)
integrator
05-17-07 02:43

From linux-2.6.21.1/kernel/kmod.c, line 64:

int request_module(const char *fmt, ...)
{
    va_list args;
    char module_name[MODULE_NAME_LEN];
    unsigned int max_modprobes;
    int ret;
    char *argv[] = { modprobe_path, "-q", "--", module_name, NULL };
    static char *envp[] = { "HOME=/",
                "TERM=linux",
                "PATH=/sbin:/usr/sbin:/bin:/usr/bin",
                NULL };
[--SNIP--]

So the kernel *does* set PATH before calling modprobe. What kernel version are you using?
 
(0002363)
iggarpe
05-17-07 04:28

I'm using 2.6.20.11. The code snippet is the same.

Something must be wrong somewhere. Busybox's /sbin/modprobe keeps failing and I'm absolutely sure it is because the PATH is not set. I've tried to replace it by a sheel script that just does write all the environment variables to a file and still I don't see the PATH set.

I'll investigate further and get back.
 
(0002364)
iggarpe
05-17-07 07:42

Back. Unable to reproduce the problem using the pristine busybox-1.5.0 sources. I still have the system in which I detected the problem and it persists.

Most probably, my fault for messing with modprobe while investigating an udevd PATH issue.

Please dismiss this bug report.
 
(0002365)
integrator
05-17-07 08:51

Closing as reporter says it no longer happens.
 

- Issue History
Date Modified Username Field Change
05-17-07 00:13 iggarpe New Issue
05-17-07 00:13 iggarpe Status new => assigned
05-17-07 00:13 iggarpe Assigned To  => BusyBox
05-17-07 02:39 integrator Assigned To BusyBox => integrator
05-17-07 02:43 integrator Note Added: 0002362
05-17-07 04:28 iggarpe Note Added: 0002363
05-17-07 07:42 iggarpe Note Added: 0002364
05-17-07 08:51 integrator Status assigned => closed
05-17-07 08:51 integrator Note Added: 0002365
05-17-07 08:51 integrator Resolution open => unable to reproduce


Copyright © 2000 - 2006 Mantis Group
Powered by Mantis Bugtracker