Maker.io main logo

How to Build a Plex Server on a Raspberry Pi 5

58

2025-03-31 | By Travis Foss

License: See Original Project Single Board Computers Raspberry Pi SBC

Have you ever wanted to back up your DVD collection? Maybe you would like to see a similar ‎interface to what you see on Netflix or Disney Plus with all your movies, TV shows, and music. I ‎recently had this idea, and after talking with a coworker, I was told about Plex. For those of you ‎who are not aware, Plex is a media server software that lets you organize, stream, and access ‎your personal media library (movies, TV shows, music, and photos) across multiple devices. Plex ‎can handle several different file formats for both video (MP4, MKV, MOV, WMV, and more) and ‎audio (mp3, FLAC, WAV, and more). Plex is free to use, however, they do have some other features ‎such as being able to download your content through Plex or streaming to a mobile device if you ‎buy the Plex pass.

plex_1

In searching for ways to build my Plex server, I discovered the idea of using Casa OS on a ‎Raspberry Pi to build a Plex server. Casa OS is an open-source home cloud operating system ‎designed for self-hosted applications. It provides a web-based graphical interface for managing ‎your personal cloud services, Docker containers, and local file storage.‎

To create this server, I gathered a few essential parts. I decided to use a Raspberry Pi 5 as the ‎main controller. Since Raspberry Pi 5s can run a bit warm, I added an active cooler to keep things ‎nice and cool. For testing, I hadn’t decided on which case I would use yet, so I added the ‎Raspberry Pi Bumper to the board as well. For storing my media, I used a 4TB Toshiba hard drive I ‎had on hand with my movies already on it. To get started quickly, I used a 64GB SD card from ‎Raspberry Pi that had Raspberry Pi OS preinstalled on it. Additionally, I utilized Raspberry Pi's 27W ‎power supply and a Micro HDMI to HDMI-A cable, also from Raspberry Pi.‎

To get started on this project, I inserted the Micro SD card into the cardholder slot on the bottom ‎of the Pi, plugged in the power cord to the USB C power slot, plugged the micro-HDMI cable into ‎one of the Pi’s HDMI ports and my monitor, and powered the system up. Once the system was ‎powered up, I went to the terminal and ran the below commands to update and upgrade the ‎system.‎

Copy Code
Sudo apt update

Sudo apt full-upgrade -y

Once this was complete, the Raspberry Pi was now up to date. The next step was to install Casa ‎OS. This was a really easy process as well. I visited the Casa OS website( CasaOS - A simple, ‎easy-to-use, elegant open-source personal cloud system) and just below the live demo button, ‎there was the command that needed to be added to the terminal. At the time of writing this ‎project up the command was as follows.‎

Copy Code
curl -fsSL https://get.casaos.io | sudo bash

After entering the command, the system installed the Casa OS software. Once the installation ‎was complete, I opened a browser window on another device and entered the Raspberry Pi's IP ‎address. If you're not sure of your Pi's IP address, you can find it by entering the following ‎command into the terminal.‎

Copy Code
hostname -I

Once my IP address was entered, Casa OS asked me to set up a username and password. Once ‎the username and password were set, the below page appeared.‎

page_2

Initially, the Plex application would not be installed, however I installed it right away. To do this I ‎clicked on the App Store icon. The app store opened and showed a list of the apps that are ‎available. Near the left side of the page, there was a search bar just under the scrolling featured ‎apps bar. I typed in Plex into that search bar and received the below result.

result_3

I ran into a bit of an issue when I got to this point of my installation. After installing the first version ‎of Plex with the greyed-out words BigBear CasaOS underneath, I tried opening the app and was ‎greeted by the error page shown below.

app_4

After a few hours of trying different things, I frustratingly installed a different version of the Plex ‎app. If you notice on the bottom left, it says Media and not BigBear Casa Os as the first one on the ‎list says. This one opened for me without issue.

version_5

Once this app had finished installing, the icon appeared on the home screen of Casa OS. ‎

I next went into the Plex app and tried to set it up. After finding some frustration in adding my hard ‎drive to Plex, I’d recommend that new users mount their hard drive to the Pi before doing this step. ‎It will save a lot of agony that I went through if this step is done first. To walk through the process ‎of mounting the Hard drive, I recommend you check out this article, How To Connect a Drive ‎‎(HDD/SSD) to a Raspberry Pi. I struggled for a while not realizing that the drive needed to be ‎mounted to the Pi for Plex to find it. In Casa OS it shows that the drive was there, and I could view ‎and test all of the files, but I couldn’t get them to load into Plex until mounting the drive was ‎completed. So, if you having issues like I did, take a look at the above link.‎

Now that the hard drive has been mounted to a folder on the Pi, the next step is setting up the Plex ‎server. Open the Casa OS page and click on the Plex app. The Plex app should then open and ask ‎for login information. The first page that will open will look like the one below.‎

drive_6

After creating and entering a login, I proceeded to the server setup page. On that page, I needed to ‎provide the server with a name. As you can see below, MYSERVER was used as the server’s name ‎in this case. Once this was done, I clicked next.‎

setup_7

The next page asks what type of media you would like to add. I clicked the add library button, ‎followed by selecting the movies button.‎

page_8

page_9

page_10

From there I navigated to the folder where I mounted my USB hard drive and selected it.‎

I then clicked the next button which brought me to the main title screen. It may take a few ‎minutes depending on how much media you have but they should start loading into your Plex ‎server.‎

Once that step was done, the Plex server was now up and running. I was able to log into Plex from ‎any smart TV or device on my network and view my library of movies, TV shows, and music.

running_11

I’m still learning more about this software, as it is still very new to me. Since putting together the ‎build, I’ve added a few more of my DVDs that I’ve found by using a couple of different software’s. ‎I’ve been using MakeMKV and also Handbrake to do this, however, there are probably other ‎programs out there that will do the same. So far, I’m really pleased with this and can see that it ‎will be an awesome addition to our family’s media storage.

制造商零件编号 SC1111
SBC 2.4GHZ 4 CORE 4GB RAM
Raspberry Pi
制造商零件编号 SC1148
ACTIVE COOLER
Raspberry Pi
制造商零件编号 SC1655
RASPBERRY PI BUMBPER
Raspberry Pi
制造商零件编号 SC0339L
64GB NOOBS MICROSD CARD
Raspberry Pi
制造商零件编号 SC1158
27W USB-C PSU UL(US), BLACK
Raspberry Pi
制造商零件编号 SC0531
CBL HDMI-A M TO MCR HDMI-D M 2M
Raspberry Pi
Add all DigiKey Parts to Cart
Have questions or comments? Continue the conversation on TechForum, DigiKey's online community and technical resource.