Ubuntu

How to Install Plex on Ubuntu 24.04

Plex Media Server is a go-to solution for anyone looking for an organized way of accessing their media libraries across different devices. Plex is a cross-platform tool that revamps the streaming experience of its users and if using Ubuntu 24.04, you can quickly install Plex in a few steps.

Throughout today’s post, we will discuss two methods for installing Plex on Ubuntu 24.04. Choose the method that is ideal for your case. Once Plex installs, you will configure your account and enjoy your streaming. Let’s begin!

Method 1: Install Plex Via Snap

Plex Media Server s available on the app center. When you install it as a snap package, the installation will handle all the dependencies, and with only one command, you will have Plex installed on your Ubuntu 24.04.
Here’s how you install Plex on Ubuntu 24.04 as a snap package.

$ sudo snap install plexmediaserver

Snap will download and install the Plex package and a progress bar will display on the terminal. Once the installation completes, you are ready to setup Plex by adding a rule in your firewall to allow traffic through its default port. More on this is covered in the next method.

Method 2: Install Plex Via APT

A better way of installing and configuring Plex is to add its official repository to your Ubuntu system. This method involves more steps, but we’ve detailed them to make it easy.

Step 1: Update Ubuntu
Since we want to add a new repository to the source list, let’s start by refreshing the package index.

$ sudo apt update

Step 2: Install Prerequisite Packages
Next, there are various dependencies we require for a successful installation of Plex media that might not already be installed. For instance, we need wget to download the GPG key. Install these packages with the below command.

$ sudo apt install wget apt-transport-https

For our case, we already have them installed, but if they are not installed on your end, please confirm the prompt and complete installing them.

Step 3: Import the Plex Repository
Here, there are two things we must do, First, let’s add the Plex repository using the below command.

$ echo deb https://downloads.plex.tv/repo/deb public main | sudo tee /etc/apt/sources.list.d/plexmediaserver.list

Next, we need to import a GPG key to validate the added repository and ensure we install the correct Plex package. To do that, let’s use wget with the below command.

$ wget https://downloads.plex.tv/plex-keys/PlexSign.key cat  PlexSign.key | sudo gpg --dearmor -o /etc/apt/trusted.gpg.d/PlexSigkey.gpg

Step 4: Install Plex on Ubuntu 24.04
With the Plex repository added to our source list, let’s quickly refresh the package index by running an update command.

$ sudo apt update

We can now install Plex through APT as follows.

$ sudo apt install plexmediaserver

Confirm any prompts that will appear and ensure the process is completed.

Step 5: Start Plex
Once installed, the first task is to check if Plex is running. Check its status using systemctl.

$ sudo systemctl status plexmediaserver.service

Suppose the service is not active; use the below commands to enable and start it.

$ sudo systemctl enable plexmediaserver.service
$ sudo systemctl restart plexmediaserver.service

Step 6: Configure Firewall
Plex media server uses port 32400. Thus, we need to configure our firewall to allow connections via this port. To do so, add a rule like the one below.

$ sudo ufw enable
$ sudo ufw allow 32400

Step 7: Set Up Plex Media Server
The last step involves accessing Plex on your browser and setting up your account. Start by opening your browser and accessing the site: http://your_ip:32400/web.

Once the site loads, you can sign up or log in to your account and enjoy the privileges of using the Plex media server.

Conclusion

Plex media server gives users room to enjoy streaming services across different devices. You can install Plex on Ubuntu 24.04 via snap or by adding its repository and installing it via APT. We’ve covered both methods and with this insight, you can comfortably install Plex on Ubuntu 24.04 and enjoy your streaming.

About the author

Denis Kariuki

Denis is a Computer Scientist with a passion for Networking and Cyber Security. I love the terminal, and using Linux is a hobby. I am passionate about sharing tips and ideas about Linux and computing.