Evan Harmon - Memex

Unraid

img Unraid is a proprietary Linux-based operating system designed to run on home media server setups that operates as a network-attached storage device, application server, and virtualization host. Unraid is proprietary software developed and maintained by Lime Technology, Inc. Users of the software are encouraged to write and use plugins and Docker applications to extend the functionality of their systems.
wikipedia:: Unraid
url:: Unraid
subreddit:: Unraid: Unleash Your Hardware

Plugins

Community Apps

  • Valheim
  • Self-hosted tools
  • Binhex-deluge-vpn
    - YouTube
    - Mullvad VPN
    - Setting up mullvad with binhex-rtorrentvpn : r/unRAID

    First we're going to create the wg0 config file. (we are using wiregaurd because openvpn is an older standard and has a longer round trip and slower speeds)

    Log into your Mullvad account and navigate to this page

    Click Linux and Generate a key

    Find what server you want. If strictly for downloading I would recommend a lower congestion server. Ie: if in LA pick an AZ server etc. Select "Only IPV4" <--- Container will not run w/ Ipv6 and then download the zip archive

    Extract a wireguard file from the archive --They will be named "mullvad-us161.conf". right click and Rename this file to wg0.conf . Make sure it saves as a .conf file and not a .conf.txt file

    Go to your binhex vpn container of choice (I'm using binhex-privoxyvpn but this works for any of his containers w/ vpn). And select these settings. Do Not enter a username or password. Custom for the vpn_provider and wiregaurd VPN_CLIENT. Start the container without the file. This will generate your wiregaurd folder.

    The container will stop on it's own due to no vpn tunnel connection. Go to your favorite SFTP tool (or SMB share) and navigate to your "/mnt/user/appdata/binhex-YOURVPNCONTAINERNAME/wireguard" and drop the wg0 file in.

    Start your container and open the console for the container and enter:

    curl https://am.i.mullvad.net/connected

User Scripts & cron jobs

Upgrade

  • backup flash drive before - easy to download in the admin ui

Array

  • Bit checking via lining up all drives and seeing if the result changes - odd/even
  • Parity drive needs to be largest or same as largest drive
  • Heterogeneous drives possible
  • Parity checks need to be done periodically as opposed to continually with other RAIDs
  • Can do 1 or 2 parity drives

Array Drives

Parity Checks

RAID Modifications

Expand Array

Replace drive/Add drive
  1. Stop the array
  2. Unassign the old drive if still assigned (to unassign, set it to No Device)
  3. Power down
  4. [ Optional ] Pull the old drive (you may want to leave it installed for Preclearing or testing)
  5. Install the new drive
  6. Power on
  7. Assign the new drive in the slot of the old drive
  8. Go to the Main -> Array Operation section
  9. Put a check in the Yes, I'm sure checkbox (next to the information indicating the drive will be rebuilt), and click the Start button
  10. The rebuild will begin, with hefty disk activity on all drives, lots of writes on the new drive and lots of reads on all other drives
  11. : All of the contents of the old drive will be copied onto the new drive, making it an exact replacement, except possibly with more capacity than the old drive.

Cache Drive

  • Usually you'd want an SSD for your cache drive
  • Writes go to cache drive first, then on a regular schedule are moved to the array, e.g. after hours.
  • Use the cache drive for things like docker containers, app data, etc.
  • So, ideally you'd want 2 cache drives so that data is protected

Cache storage options

  • on cache
  • array and cache
  • array only

Mover

Flash Drive

  • Flash Drive | Unraid Docs
  • Boots from usb flash drive and runs unraid from system memory
  • License key attached to specific flash drive
  • Can backup flash drive with appdata plugin

System files

  • appdata: houses our docker’s container configuration content
  • domains: houses our VM’s data
  • system: houses our docker’s docker.img and our VM’s libvrt.img

Troubleshooting, Fixes

  • Device is disabled, contents emulated
    - Stop the array, unassign the disk, start the array in maintenance mode, stop it again, reassign the drive to the same slot. The idea is to start the array temporarily with the drive “missing” so it changes from “disabled” to “emulated” status, then to stop it and “replace” the drive to get it back to “active” status.
    	- [How do I re-enable a disabled disk drive??? : r/unRAID](https://www.reddit.com/r/unRAID/comments/u3nhmg/how_do_i_reenable_a_disabled_disk_drive/)
    

Settings, Config, etc.

Docker On Unraid

  • Route a container to another container's network - e.g. to use a container's vpn
    - documentation/docker/faq/vpn.md at master · binhex/documentation
    - Gist:
    - On "client" docker:
    - extra args: --net=container:binhex-delugevpn
    - set network to none
    - delete any existing port mappings, e.g. for its web ui
    - On "server" docker with the network:
    - add the client's docker port as an extra port mapping
    - at least on binhex-delugevpn, I needed to add that port to that container's variable called vpn inputs or something like that.

    Please keep in mind that when defining connections from an application to another application in the same VPN container network that you will need to set the host to 'localhost' and NOT the LAN IP address, this is because the applications are now bound to the same network and thus should communicate over 'localhost' and NOT the unRAID host IP address.

    The order of containers starting is now important, the VPN container must start first in order for the other container(s) to route through it, ordering can be changed in the unRAID Web UI by dragging the containers up and down, the unRAID Web UI shows the start order in descending order.

Tools

Sources

Inbox

Unraid
Interactive graph
On this page
Unraid
Plugins
Community Apps
Backup
User Scripts & cron jobs
Upgrade
Array
Array Drives
Parity Checks
RAID Modifications
Expand Array
Replace drive/Add drive
Cache Drive
Cache storage options
Mover
Flash Drive
System files
Troubleshooting, Fixes
Settings, Config, etc.
Docker On Unraid
Tools
Sources
Inbox