From cb99eb171a3863971d6211232c52ad80ed140ad0 Mon Sep 17 00:00:00 2001 From: Michele Cereda Date: Sat, 15 Nov 2025 21:07:57 +0100 Subject: [PATCH] chore(openmediavault): add notes about other features --- knowledge base/clamav.md | 14 +- .../linux/bond network interfaces.md | 123 ++++++++++++++++++ knowledge base/openmediavault.md | 23 +++- 3 files changed, 147 insertions(+), 13 deletions(-) create mode 100644 knowledge base/linux/bond network interfaces.md diff --git a/knowledge base/clamav.md b/knowledge base/clamav.md index 21d9b29..75ca3e9 100644 --- a/knowledge base/clamav.md +++ b/knowledge base/clamav.md @@ -79,10 +79,11 @@ find . -type f | parallel --group --jobs 0 -d '\n' clamscan {} - [Codebase] - [Documentation] - [Gentoo Wiki] +- [On-Access Scanning] ### Sources -- [Install ClamAV on Fedora Linux 35] +- [Install ClamAV on Fedora Linux] -[codebase]: https://github.com/Cisco-Talos/clamav -[documentation]: https://docs.clamav.net/ -[website]: https://www.clamav.net/ +[Codebase]: https://github.com/Cisco-Talos/clamav +[Documentation]: https://docs.clamav.net/ +[On-Access Scanning]: https://docs.clamav.net/manual/OnAccess.html +[Website]: https://www.clamav.net/ -[gentoo wiki]: https://wiki.gentoo.org/wiki/ClamAV -[install clamav on fedora linux 35]: https://www.linuxcapable.com/how-to-install-clamav-on-fedora-35/ +[Gentoo Wiki]: https://wiki.gentoo.org/wiki/ClamAV +[Install ClamAV on Fedora Linux]: https://linuxcapable.com/install-clamav-on-fedora-linux/ diff --git a/knowledge base/linux/bond network interfaces.md b/knowledge base/linux/bond network interfaces.md new file mode 100644 index 0000000..85efb82 --- /dev/null +++ b/knowledge base/linux/bond network interfaces.md @@ -0,0 +1,123 @@ +# Bond network interfaces + +Combines multiple network interfaces into a single logical interface.
+Provides benefits such as increased bandwidth, redundancy, and load balancing. + +1. [TL;DR](#tldr) +1. [Bonding modes](#bonding-modes) +1. [Configuration](#configuration) +1. [Further readings](#further-readings) + 1. [Sources](#sources) + +## TL;DR + +Linux bonding is implemented through the `bonding` kernel module.
+It implements several [bonding modes], each with its own characteristics and use cases. + +If one's switches support LACP, prefer using mode 4 (802.3ad) for compatibility and optimal performance.
+LACP allows the Linux system and the switch to negotiate the link aggregation settings automatically. + + + +
+ Usage + +```sh +# Check the status of the bonding interface. +cat '/proc/net/bonding/bond0' + +# Test the redundancy of the bonding interface. +# Simulates a failure of one of the slave interfaces. +ifconfig 'eth0' down; sleep 30s; ifconfig 'eth0' up +``` + +
+ + + +## Bonding modes + +| ID | Mode name | Summary | Use cases | +| --- | ------------------------------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------- | +| 0 | Round Robin | Sends packets out sequentially on each available slave interface.
Provides load balancing across all used interfaces and increases the overall bandwidth. | Environments where bandwidth aggregation is the primary goal and all connected switches support load balancing | +| 1 | Active-Backup | Only one slave interface is active at a time. If the active interface fails, the driver automatically switches to one of the backup interfaces. | Scenarios where redundancy is crucial, such as in mission-critical applications | +| 2 | XOR | The driver uses a hash function to determine which slave interface to send a packet on. The hash is based on the source and destination MAC addresses. | Networks where the traffic patterns are relatively stable, and the same source-destination pairs are likely to be used frequently | +| 3 | Broadcast | All packets are sent out on all slave interfaces. Provides high redundancy, but consumes a lot of network resources. | | +| 4 | 802.3ad, Link Aggregation Control Protocol | Requires support from the connected switches. Creates a link aggregation group (LAG) between the Linux system and the switch. Provides both load balancing and redundancy. | Environments where high bandwidth and reliability are required | +| 5 | Balance-TLB | Dynamically distributes **outgoing** traffic to the interface with the least load. | Environments where the traffic distribution is uneven and load balancing is required | +| 6 | Balance-ALB | Distributes both outgoing and incoming traffic across all slave interfaces | Networks where both high bandwidth and load balancing are required | + +## Configuration + +1. Load the `bonding` module: + + ```sh + modprobe 'bonding' + ``` + +1. Create a bonding interface. + + Add a configuration file in the `/etc/sysctl.d/` directory: + + ```conf + # /etc/sysctl.d/bond0.conf + # miimon: interval (in milliseconds) at which the bonding driver checks the link status of the slave interfaces + bonding.modes=mode=6 miimon=100 + ``` + +1. Add the slave interfaces: + + ```conf + # /etc/network/interfaces + + auto bond0 + iface bond0 inet static + address + netmask + gateway + bond-mode + bond-miimon 100 + bond-slaves eth0 eth1 + ``` + +1. Restart the network service: + + ```sh + sudo systemctl restart networking + ``` + +## Further readings + +### Sources + +- [Understanding Linux Bonding Modes] + + + + +[Bonding modes]: #bonding-modes + + + + + +[Understanding Linux Bonding Modes]: https://linuxvox.com/blog/linux-bonding-modes/ diff --git a/knowledge base/openmediavault.md b/knowledge base/openmediavault.md index 516b3b0..6bea938 100644 --- a/knowledge base/openmediavault.md +++ b/knowledge base/openmediavault.md @@ -25,23 +25,31 @@ Default web UI login is `admin`:`openmediavault`. ```sh # Make users OMV administrators. -gpasswd -a 'me' 'openmediavault-admin' usermod -aG 'openmediavault-admin' 'me' +gpasswd -a 'me' 'openmediavault-admin' +adduser 'me' 'openmediavault-admin' + +# Allow users to connect via SSH. +usermod -aG '_ssh' 'me' +gpasswd -a 'me' '_ssh' +adduser 'me' '_ssh' # Revoke WebUI access from the 'admin' user. gpasswd -d 'admin' 'openmediavault-admin' deluser 'admin' 'openmediavault-admin' # Install plugins from the CLI. -apt install 'openmediavault-clamav' +apt install 'openmediavault-clamav' … 'openmediavault-nut' # Install OMV-Extras. wget -O - 'https://github.com/OpenMediaVault-Plugin-Developers/packages/raw/master/install' | bash -# Disable the kernel's backports sources. -mv -v \ - '/etc/apt/sources.list.d/openmediavault-kernel-backports.list' \ - '/etc/apt/sources.list.d/openmediavault-kernel-backports.list.disabled' +# Use ZFS. +# Requires OMV-Extras. +apt install 'openmediavault-kernel' +# Install the Proxmox kernel and reboot +apt install 'openmediavault-zfs' +zpool import -a # Upgrade packages. sudo omv-upgrade @@ -197,7 +205,8 @@ From the CLI, as the `root` user: 1. Install the `openmediavault-clamav` plugin. 1. Enable the service under _Services_ > _Antivirus_ > _Settings_. -1. Apply pending changes. +1. Apply pending changes.
+ The first run will take a long time. ## UPS