mirror of
https://github.com/unraid/webgui.git
synced 2026-02-06 08:59:01 -06:00
28 lines
1.2 KiB
Bash
Executable File
28 lines
1.2 KiB
Bash
Executable File
#!/bin/bash
|
|
|
|
# /etc/rc.d/rc.modules.local
|
|
|
|
# The Linux kernel source is the best place to look for documentation
|
|
# for the many available kernel modules. This can be found under
|
|
# /usr/src/linux-$VERSION/Documentation/.
|
|
|
|
# Almost all necessary modules are automatically loaded when needed,
|
|
# but there are a few exceptions. Here's a (not all-inclusive) list,
|
|
# so uncomment any of the below entries or add others as needed:
|
|
# Note that you could also create/edit rc.modules-$version if you
|
|
# only wanted specific modules loaded for particular kernels.
|
|
|
|
#/sbin/modprobe tun # Universal TUN/TAP device driver
|
|
#/sbin/modprobe sg # Generic SCSI support for SATA DVD-RW
|
|
|
|
# limetech - set default zfs arc size to 1/8 total memory
|
|
# (MemTotal is reported in units of 1024, SIZE needs to be bytes)
|
|
SIZE=$(awk '/MemTotal/{print $(NF-1)*128}' /proc/meminfo)
|
|
echo "# limetech - Default ARC size is MemTotal/8 (in bytes)" > /etc/modprobe.d/zfs.conf
|
|
echo "options zfs zfs_arc_max=$SIZE" >> /etc/modprobe.d/zfs.conf
|
|
|
|
# limetech - grab any user defined module conf files
|
|
if [ -d /boot/config/modprobe.d ]; then
|
|
/usr/bin/find /boot/config/modprobe.d -type f -exec install -p -m 0644 {} /etc/modprobe.d \;
|
|
fi
|