Man Pages (1MTSOL): Maintenance and Administration Commands
この本のみを検索
PDF 文書ファイルをダウンロードする

NAME

modload - Load a kernel module

SYNOPSIS

modload [ -p ] [ -e exec_file ] filename

AVAILABILITY

SUNWcsu

DESCRIPTION

modload loads the loadable module filename into the running system. filename is an object file produced by ld -r. If filename is an absolute path name, then the file specified by that absolute path is loaded. If filename does not begin with a slash (/), then the path to load filename is relative to the current directory unless the -p option is specified. The kernel's modpath variable can be set using the /etc/system file. The default value of the kernel's modpath variable is set to the path where the operating system was loaded. Typically this is /kernel /usr/kernel. Hence if you type
        example# modload drv/foo
then the kernel will look for ./drv/foo. If you type
        example# modload -p drv/foo

then the kernel will look for /kernel/drv/foo and then /usr/kernel/drv/foo.

OPTIONS

-p
Use the kernel's internal modpath variable as the search path for the module.
-e exec_file
Specify the name of a shell script or executable image file that is executed after the module is successfully loaded. The first argument passed is the module ID (in decimal). The other argument is module specific. This information is module-specific: the block and character major numbers for drivers, the system call number for system calls, or, for other module types, the index into the appropriate kernel table. See modinfo(1M).

SUMMARY OF TRUSTED

To succeed, this command needs the sys_devices privilege.

SOLARIS CHANGES

SEE ALSO

ld(1), add_drv(1MTSOL), kernel(1M), modinfo(1M), modunload(1MTSOL), system(4), modldrv(9S), modlinkage (9S),modlstrmod(9S), module_info(9S)
Writing Device Drivers
Solaris 1.x to 2.x Transition Guide

NOTES

Use add_drv(1M), not modload, to add device drivers. See Writing Device Drivers for procedures on adding device drivers.