diff --git a/knowledge base/diy nas/v1.md b/knowledge base/diy nas/v1.md index 009d8fa..94c8ae2 100644 --- a/knowledge base/diy nas/v1.md +++ b/knowledge base/diy nas/v1.md @@ -3,6 +3,7 @@ ## Table of contents 1. [Hardware](#hardware) +1. [Software](#software) 1. [Further readings](#further-readings) 1. [Sources](#sources) @@ -18,6 +19,15 @@ | RAM | [Crucial CT2K16G4SFRA32A] 32GB kit (2x16GB) | [€67,95][amazon crucial ct2k16g4sfra32a] | | SATA cables | Cable Matters 6.0Gbps SATA III cable with 90 degrees angle, black, 45cm | €11,98 (2x [€5,99][amazon cable matters sata cables]) | +## Software + +| Component | Choice | Notes | +| ---------------- | ---------------- | -------------------------------------------------- | +| Operating system | [OpenMediaVault] | With [OMV-Extras](../openmediavault.md#omv-extras) | +| Kernel | Default (Debian) | | +| OS file system | Default (ext4) | | +| Data file system | ZFS | See [ZFS](../openmediavault.md#zfs) | + ## Further readings - [OpenMediaVault] diff --git a/knowledge base/openmediavault.md b/knowledge base/openmediavault.md index 6bec9e8..cdb400e 100644 --- a/knowledge base/openmediavault.md +++ b/knowledge base/openmediavault.md @@ -7,14 +7,33 @@ NAS solution based on [Debian Linux][debian]. 1. [TL;DR](#tldr) 1. [Make other users administrators](#make-other-users-administrators) 1. [Remove access for the default admin user](#remove-access-for-the-default-admin-user) +1. [OMV-Extras](#omv-extras) +1. [ZFS](#zfs) + 1. [ZFS plugin](#zfs-plugin) 1. [Further readings](#further-readings) 1. [Sources](#sources) ## TL;DR ```sh +# Make other users administrators. +gpasswd -a 'me' 'openmediavault-admin' +usermod -aG 'openmediavault-admin' 'me' + +# 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' + # 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' ``` ## Make other users administrators @@ -47,6 +66,43 @@ From the safest to the less safe option: deluser 'admin' ``` +## OMV-Extras + +From the CLI, as the `root` user: + +1. Install [OMV-Extras]: + + ```sh + wget -O - \ + 'https://github.com/OpenMediaVault-Plugin-Developers/packages/raw/master/install' \ + | bash + ``` + +## ZFS + +### ZFS plugin + +1. [Install OMV-Extras]. +1. Pick one: + + - Disable the kernel's backports APT sources and stick to the mainline one.
+ Linux backport kernels are released quickly enough to leave the userland incomplete at times. This often happens with ZFS, resulting in broken package issues. + + ```sh + mv -v \ + '/etc/apt/sources.list.d/openmediavault-kernel-backports.list' \ + '/etc/apt/sources.list.d/openmediavault-kernel-backports.list.disabled' + ``` + + - Install the `openmediavault-kernel` plugin and use it to install the Proxmox kernel.
+ Debian does not build ZFS kernel modules into any of their kernels by default due to licensing conflicts. This may result in an extensive build process during installation, which is prone to errors. + + The Proxmox-Debian kernel has the ZFS kernel modules preinstalled by default. As kernel upgrades become available and are performed, the userland for the Proxmox kernel will always have the required packages to support ZFS. + +1. Install the `openmediavault-zfs` plugin. +1. Create pools and such.
+ You might need to wipe the disks first. + ## Further readings - [Website] @@ -60,6 +116,7 @@ From the safest to the less safe option: All the references in the [further readings] section, plus the following: - [How to lock or disable an user account] +- [ZFS plugin for OMV6] [omv-extras]: https://wiki.omv-extras.org/ [website]: https://www.openmediavault.org/ +[zfs plugin for omv6]: https://wiki.omv-extras.org/doku.php?id=docs_in_draft:zfs [further readings]: #further-readings [make other users administrators]: #make-other-users-administrators +[omv-extras]: #omv-extras [debian]: debian.md