-
Notifications
You must be signed in to change notification settings - Fork 49
Inserting and Removing the Kernel Modules
When the RapidDisk module is loaded, the /sys/kernel/rapiddisk/mgmt file is created and used to manage all RapidDisk block devices. When the module is inserted, you can read the proc file for quick module details:
$ cat /sys/kernel/rapiddisk/mgmt
RapidDisk 4.0
Maximum Number of Attachable Devices: 128
Number of Attached Devices: 0
Max Sectors (KB): 127
Number of Requests: 128
If the module is installed (via Makefile):
$ sudo modprobe rapiddisk
If the module is not installed but is built in your local path:
$ sudo insmod rapiddisk.ko
If the module is installed (via Makefile):
$ sudo modprobe -r rapiddisk
OR
$ sudo rmmod rapiddisk.ko
Obtaining module information (module must be loaded into kernel)
$ modinfo rapiddisk
filename: /lib/modules/3.10.0-327.4.5.el7.x86_64/kernel/drivers/block/rapiddisk.ko
Copyright: Copyright 2010 - 2015 Petros Koutoupis
version: 4.0
description: RapidDisk is an enhanced RAM disk block device driver.
author: Petros Koutoupis
license: GPL
rhelversion: 7.2
srcversion: C6AE255BA24B99FDF255C44
depends:
vermagic: 3.10.0-327.4.5.el7.x86_64 SMP mod_unload modversions
parm: max_sectors: Maximum sectors (in KB) for the request queue. (Default = 127) (int)
parm: nr_requests: Number of requests at a given time for the request queue. (Default = 128) (int)
parm: rd_nr: Maximum number of RapidDisk devices to load on insertion. (Default = 0) (int)
parm: rd_size: Size of each RAM disk (in KB) loaded on insertion. (Default = 0) (int)
parm: rd_max_nr: Maximum number of RAM Disks. (Default = 128) (int)
If the module is installed (via Makefile):
$ sudo modprobe rapiddisk-cache
If the module is not installed but is built in your local path:
$ sudo insmod rapiddisk-cache.ko
If the module is installed (via Makefile):
$ sudo modprobe -r rapiddisk-cache
OR
$ sudo rmmod rapiddisk-cache.ko
Obtaining module information (module must be loaded into kernel)
$ modinfo rapiddisk-cache
filename: /lib/modules/3.10.0-327.4.5.el7.x86_64/kernel/drivers/block/rapiddisk-cache.ko
Copyright: Copyright 2010 - 2015 Petros Koutoupis
version: 4.0
description: RapidDisk-Cache DM target is a write-through caching target with RapidDisk volumes.
author: Petros Koutoupis
license: GPL
rhelversion: 7.2
srcversion: AF2C35BCCFBAEC20D089558
depends: dm-mod
vermagic: 3.10.0-327.4.5.el7.x86_64 SMP mod_unload modversions
When invoking a DKMS install via the source code’s Makefile, the installer will copy the module source in the /usr/src directory path and then run the dkms utility to add, built, and install the collection of modules. The advantage to doing this is that whenever your kernel updates, the dkms infrastructure will automatically rebuild the modules and install them for the new kernel. That way, on your next system reboot to the new kernel image, you will also have the modules available without interruption. To invoke the DKMS install, type the following at the root of the package source:
$ sudo make dkms-install