How to Set Up TrueNAS Scale to Host Plex – Page 2 – TechMikeNY
Back To Top

RECENT ARTICLES

Another Use for a Raspberry Pi: Pimoroni Enviro + Air Quality Setup Guide

Another Use for a Raspberry Pi: Pimoroni E...

Fri, May 31, 24

  Here at TechMikeNY, we love Raspberry Pis. And as you know,...

Setting Up a RAID 1 Virtual Disk in UEFI

Setting Up a RAID 1 Virtual Disk in UEFI

Wed, May 22, 24

It's a bird, it's a plane, it's... another RAID tutorial from TechMikeNY?...

How to Configure a BOSS Card: Setting Up RAID

How to Configure a BOSS Card: Setting Up RAID

Wed, May 15, 24

If you don't have fault tolerance for your OS and your drive...

Upcycling Projects: Turning a Chassis Into a Planter

Upcycling Projects: Turning a Chassis Into...

Mon, May 06, 24

As you may know, TechMike’s office is practically a jungle at this...

VIEW ALL

How to Set Up TrueNAS Scale to Host Plex

How to Set Up TrueNAS Scale to Host Plex


If you’ve been thinking about setting up a centralized media server of your own, there’s a good chance you’ve come across Plex, a media server software that allows you to organize, stream, and access your personal media collection across various devices. To set up Plex, you need a reliable, high-performance hosting solution. That’s where TrueNAS Scale comes in.

TrueNAS Scale is a powerful free network-attached storage (NAS) with an easy to understand graphical user interface, making set-up a relatively intuitive process. In this guide, we’ll walk you through the process of installing and configuring TrueNAS & Plex so you can have your media server running in no time.

Set-up checklist: 

 
  • An internet connection.
  • good desktop to install and run TrueNAS Scale on. According to the TrueNAS Website, TrueNAS SCALE can run on any x86_64 compatible (Intel or AMD) processor, but it requires at least 8GB of RAM (more is better).
  • A 2nd desktop to access TrueNAS WebUI and Plex.
  • A boot device; according to Plex, you’ll want to use at 20GB Boot Device at minimum.
  • A Plex account. You’ll need to have one set up in order to install Plex.

    Author's Note 06/2024: This tutorial has instructions for the Bluefin version of TrueNAS Scale; newer version updates have changed the way that TrueNAS Scale handles shares and app interactions. TechMikeNY will share a new tutorial for the updated process.

Why use a desktop for a media server?

Due to their ease of setup and space efficiency, using a desktop is the way to go when setting up Plex on TrueNAS. Unlike rack servers, desktops are compact, fitting well in home or small office environments; you might not want a full rack in your TV room. They also require minimal technical expertise, featuring user-friendly interfaces and straightforward installation processes, so after it's set up, it's something the whole family can use. (If you want them to.) Plus, desktops are definitely going to be the quieter option, so they won’t interrupt movie night.

Importantly, desktops also offer reduced energy consumption. Media servers generally need to be turned on all the time, and using a desktop instead of a rack server definitely saves power (and your electricity bill). Desktops also happen to excel in heat dissipation, thanks to their advanced cooling technologies. That means better performance and longer-lasting components. Essentially, setting up your media server on a desktop is the more efficient, sustainable choice.

Downloading and Installing TrueNAS

  1. Download the latest version of TrueNAS Scale from https://www.truenas.com/download-truenas-scale/.

  2. Using something like Balena Etcher, Rufus, or Ventoy, make a bootable installer. Boot the installer on the desktop/server you plan to install TrueNAS & Plex. In this tutorial, we used Ventoy.
    Here's a great tutorial we found on how to use Rufus to make a bootable installer.



  3. After the loading dialogue, select Install/Upgrade from the options presented.  Choose where you want to install TrueNAS from the list of available drives.

    Step 3.2


    You can choose 2 identical drives, if you are able to sacrifice 2 drives, to use in a Mirror configuration. That way, if one drive fails, you have a backup that can take over. Not necessary, but recommended.

    3.3


    Press YES to acknowledge that all data on the chosen drives will be erased before installing TrueNAS.

    Step 3.4


    At this point, you’ll be asked to choose how you’ll want to log in when the TrueNAS WebUI comes up. In our case, we used  “Administrative user”.  “Administrative user” will be quickest to get you going; you can set up other accounts later. Or, if you’d prefer to save setting up the admin account for when you eventually load up the TrueNAS WebUI, hit  “Configure using WebUI”.        

    Step 3.3


    Unless you’re low on RAM (think less than 32GB), you don’t need a swap partition, so select “No swap” when prompted to create a swap partition.

    The install will begin.

  1. Step 4


    Once the install is complete, reboot, and remove the installation device.

  1.  
    Step 5

    On boot, it will ask which version of TrueNAS to boot. Press Enter or just let it boot automagically. (It’s preset to boot the version we just installed. The list is just there in case you want to boot a previous version after installing updates in the future.)


Creating Pools


Once TrueNAS boots, you’ll be able to head into the WebUI to get TrueNAS ready to host Plex. The first step will be creating pools within TrueNAS.

A pool is a logical storage construct in TrueNAS that combines multiple physical drives into a single entity. Pools enable you to allocate drives, configure redundancy options like mirroring, and create datasets for organizing and managing your files and data. In this case, we’ll be creating datasets specifically intended to store media files and configuration files for Plex.


  1. Step 6

    As soon as the boot process is complete, you’ll be presented with the IP address to access the WebUI and some options for configuring things locally if you need to (optional). Otherwise, use your second device to head over to a Web browser like Chrome or Edge (or OperaGX if you’re fancy).

    You don’t need to type the port numbers in the address bar when trying to get to the WebUI, just the IP address.

    Niche note: If you've disabled DHCP, the IP address will not show here.



    Once you enter the displayed IP address into a web browser, the WebUI login page will be shown. Log in again to access the dashboard.



  1. From the dashboard, we need to create some pools with the other drives we have in the system. Select Storage on the left, and click “Create Pool”.

     A menu showing the other drives available in your system will appear. Name the pool whatever you’d like. (We chose to name it Tank.)

    Adding a Drive to the Pool

    Check the box by the drive(s) you’d like to add to the pool, and hit the arrow to add it to the pool.

    If you only have one drive to use for your Pool (as shown here), check the “Force” box at the bottom left and accept the warnings that pop up.

    Click Create Pool to finalize.


Security note on setting up the pool: To avoid data loss, it’s recommended to at least do a mirror of 2 identical drives when setting up a pool (in case one fails).

Additionally, if you want your entire pool to be encrypted, you must check the encryption box at this stage during the pool creation process. You will later be able to choose whether or not you want your child datasets encrypted, but you won’t be able to encrypt the entire pool if you don’t do so here.

Setting Up Datasets


Once the pool has been created, we need to set up two datasets on that pool. One will be a designated space for your media, and the other will hold the configuration files for Plex.




  1. Select the Datasets option on the left. Then click on the dataset for the pool you’re setting up (for us, Tank Dataset), and hit “Add Dataset” at the top right.

    Child Dataset
    Name the child dataset “Plex Config” (or something that will help you remember it’s your Plex Config dataset) before you hit Save at the bottom. You can even add a description, if you want.

    Repeat the process to create another child dataset, this one designated for media. We were really creative and named ours “Media”.



  1. Next, you’ll need to set up an SMB Share. From the “Shares” section on the left, click “Add” (located next to the “Windows (SMB) Shares” section), and set the path to point towards your “Media” dataset.

    Name the share and click “Save”. Check the box to start the SMB Service on TrueNAS automatically and click the "Enable Service" button. You'll then be taken to a screen to edit the dataset's Access Control List (ACL). You can customize the ACL configuration if you wish, but the preset configuration works as well. Scroll down and select "Save Access Control List" to continue.


ALTERNATIVE METHOD:  
If you don’t want to set up an SMB share, a simpler way of getting your media to “Media” is by installing and using File Browser within TrueNAS. File Browser is a web-based file manager app. In our case, we would use it to add media to “Media”.

For more on how to set up and use File Browser within TrueNAS, check out this helpful video.

Installing and Configuring Plex


Now you’re ready to install Plex! Well, almost;  you need to have a Plex account set up and ready before proceeding. (Here's how to create an account.)



  1. Start by heading over to the “Apps” section.  The apps will need a pool to install to, so click “Choose Pool” and select the pool that you just set up. Doing so will create a dataset for all your installed apps called ix-applications.




  2. Before you can point Plex towards the dataset you want to store your media in, you’ll need to disable host path validation. To do so, select “Advanced Settings” from the “Settings” drop down and disable “Host Path Safety Checks”. (Otherwise, TrueNAS will block you from sharing the dataset using SMB, which you need to do in order to upload media.)

    If it’s not automatically filled in, make sure that Route v4 Interface is set to the port that you have your cable connected to and that Route v4 Gateway is set to your router’s IP address.

    Save your settings to continue.


    In case you’re curious, here’s an explanation of the host path validation feature and why it's recommended to disable it.

 


  1. Step 12

    Select the “Available Applications” tab and search for Plex. Once it comes up, hit Install.

  2. You’ll be presented with a side window to configure the App.



    Enter the Claim token for your Plex Account available at plex.tv/claim. If you’ve paid for a Plex Pass, check that box.

    13.2
    Scroll down to the Storage section of the menu and check the boxes for “Enable Host Path for Plex Data volume” and “Enable Host Path for Plex Config Volume.” Then, point the Data volume towards the designated “Media” dataset you created during set-up & point the Config volume towards the designated “Plex Config” dataset.

  3. Moment of truth. Once everything is all set, double check that you’ve entered your claim token correctly and click Save to install the app and deploy it.

Setting Up Your Library


When Plex says it’s Active under the “Installed Applications” tab, you’ll need to log into the Web Portal to set up your library.



  1. Click the “Web Portal” button and log into Plex. Once you’re logged in, click through the introduction, name your Plex server, and enable remote access if your network allows for it.



    You’ll be prompted to set up your library. Choose the type of library that corresponds to what you’ll be using your server for (ex. Movies, TV Shows, Music), name it whatever you’d like, then point it to the “data” directory on the next step.

  2. To finish up, connect to the “Media” SMB share we set up in step 14. We found that you need to create a new local user in TrueNAS to be able to log into the SMB share; you can do so by going over to Credentials, then Local Users, and then hitting Add. Once you’ve added your new user, all you have to do is map the SMB share you created to the device you’ll be uploading media from.

And you’re all done. Congratulations! You now have a centralized media server. Feels good, right?

 

We hope you’ve found this guide for setting up Plex on TrueNAS helpful. If you have any questions, don’t be a stranger – drop us a line in the comments below or at info@techmikeny.com.

 9 comments

  • Hey TechMike,
    Thank you for the detailed guide, I made it through to the last step without issue, but seem to be having problems adding media to my server. Like in the other comment you responded to, I can’t get plex to recognize my media whatever I do.

    I tried separating the files out into folders inside of Media called Movies and TV Shows, but Plex won’t seem to recognize anything past one folder deep.

    It also doesn’t add the media (even if it shows up when I click the Data Tab when selecting a library) if they are in the root of the SMB Media folder.

    Any help is appreciated.

    Logan
  • Excellent guide! Everything went very well with my first foray into using TrueNAS scale using this. I had used OMV with docker and Portainer before and this is even easier.

    Josh
  • Hey Trey,

    Thanks for your question. In the final step of adding a Library to Plex, selecting “/data” during the last step is not actually adding data to Plex; it is directing Plex to look for media within the location, “/data”.

    Backtracking to Step 8, we set up 2 datasets; 1. “Plex Config”, for Plex’s configuration files, and 2.“Media”, to store your videos, pictures, and any other content that you want Plex to access.

    How does content end up in “Media”? That’s where the SMB share comes into play. The purpose of the SMB share is to be able to easily transfer your media files from your computer and into the “Media” dataset. This dataset is what Plex will access through the designated folder called “data.”

    During Step 13, when configuring Plex’s “Storage” settings, you need to check the “Enable host path for Plex Data Volume” and set the host path to the “Media” dataset. By doing this, you’re essentially telling TrueNAS to link the “Media” dataset to the “/data” folder.

    Then, when you go to add a Library and hit “Browse Media Dataset”, you’ll need to select the “/data” folder. You’ve set everything up so that whatever is in “Media” ends up in “/data”.


    Hope that helps!

    TechMike
  • Last step to add Library to Plex doesnt work. If media is the directory and shared via SMB then why you adding data to Plex.

    Trey

Leave a comment

Name . . Message .

Please note, comments must be approved before they are published