modules.load

Synopsis

modules.load <name> [name: value]...

Description

modules.load loads a kernel module with modprobe on Linux; params are passed as name=value. A module that is already loaded is unchanged. lsmod decides; - and _ are the same character in the name of a module.

Rights: the command accepts privilege; write privilege: elevated when the account that runs Nurt is not the administrator. A program that fails for lack of rights ends the command with E_PERMISSION, and privilege: auto repeats it once elevated. An elevated entry is undone by the same elevated process.

undo runs modules.unload.

Parameters

Parameter Type Default Description
name text required Module name.
params list<text> none Module parameters as name=value.

Input and output

Form Input Output
default none effect

Effect

Property Value
Category change
Effect external
Reversibility reversible_if_preserved
Implementation system_program
Reversibility conditions Undo unloads the module.
Operating systems linux
External use system_program: modprobe, lsmod; Modules are listed with lsmod and loaded with modprobe.

Examples

Load a module.

modules.load "br_netfilter" privilege: elevated

Load a module with a parameter.

modules.load "nf_conntrack" params: ["hashsize=65536"] privilege: elevated

Run the load with elevated rights; adding the call parameter preview: true shows the effect first.

modules.load "overlay" privilege: elevated

Errors

Code Meaning Typical fix
E_OS_ONLY The system is not Linux. Use the tools of the system.
E_STAGE_FAILED The module does not exist. Check the name.
E_PERMISSION The account lacks the rights of the administrator. Add privilege: elevated.
E_EXTERNAL_MISSING The system program of the command is not installed. Install the program named in the message.
E_STAGE_FAILED The system program ended with an error. Read the end of the error output in the message.

modules.unload, sysctl.set.

Source file on GitHub: docs/commands/modules.load.md