Raspberry Pi OS Lite(64-bit) was flashed to the microSD card using Raspberry Pi Imager on a Windows PC. The Pi was then connected via Pi Connect for remote terminal access.
OS Lite boots straight into a terminal with no desktop, no windows, no mouse. Everything is done through text commands. It's lighter and faster because it's not running a graphical interface in the background, which means more of the Pi's power goes to Jellyfin instead of drawing a desktop nobody is using.
Ones you have connected in Pi connect the system package list and all installed packages must be updated. This ensures we're installing the latest, most compatible versions of everything.
You can do that by pasting the command below into the terminal:
apt = the package manager on Debian/Raspberry Pi OS.
-y = automatically answer "yes" to all prompts.
Find the drive
After plugging in the external drive, this command lists all block devices (drives) so we can identify ours.
The drive appeared as sda / sda1 with 1.8TB โ confirming the Pi detected it correctly.
It's important to note that the physical drive is 2TB, however some storage is lost to formatting overhead, which is why it shows as 1.8TB.
Format the drive
The drive is going to be formatted as ext4 โ the standard Linux filesystem. It's faster and more reliable for a Linux server than NTFS (Windows format) or FAT32.
Create mount point & mount
In Linux, drives don't appear as drive letters (like D:). Instead they are "mounted" to a folder. So we create /mnt/media as the folder where the drive will live.
sudo mount /dev/sda1 /mnt/media
Then if you want to make sure that your mounting worked you can run the following command:
You should see something like this โ look for /dev/sda1 mounted at /mnt/media with roughly 1.8TB available:
/dev/sda1 1.8T 2.1M 1.7T 1% /mnt/media
If you can see /mnt/media in the list, the drive is mounted and ready to use!
Get the drive's UUID
Every drive has a unique ID (UUID). We need this to tell the Pi to auto-mount the right drive on boot โ not just "whatever is in the USB port". Makes it behave more like a permanent hard drive.
UUID looks something like: 623db798-5cca-413b-8df4-12c969db9673
Edit fstab for auto-mount
fstab is the file Linux reads on every boot to know which drives to mount and where. We added our drive so it mounts automatically every time the Pi starts.
Line added at the bottom of the file:
Final fstab file should look like:
Jellyfin has an official repository for Debian Trixie. We add the repository key, add the repo, then install Jellyfin.
Jellyfin is confirmed running when status shows active (running).
Jellyfin web UI is accessible at http://[YOUR-PI-IP]:8096 โ you can find your Pi's IP by running:
Samba is a service that lets Linux share folders over the network using Windows-compatible file sharing. This allows you to drag and drop movies directly from your PC into the Pi's media drive.
Added to the bottom of /etc/samba/smb.conf:
From Windows PC, access the share by typing in File Explorer's address bar:
Login with username JellyfinServer and the Samba password you set.
The home network might have Double NAT issue (modem + personal router) which blocked standard port forwarding. Tailscale is used instead โ it creates a secure private tunnel between devices without needing to open ports on your router.
Why Tailscale?
- โ Works with Double NAT โ no router config needed
- โ Encrypted private tunnel between your devices
- โ Free for personal use
- โ Works on Windows, Mac, Android, iOS, Linux
Install Tailscale on the Pi
Running tailscale up outputs a login URL. Open it in your browser and sign in with a free Tailscale account. The Pi then joins your private Tailscale network.
Jellyfin is now accessible from anywhere using Tailscale at:
Sharing with others
To give someone else access, go to https://login.tailscale.com, find the Pi device, click Share, and enter their email. They install Tailscale, accept the invite, and can access your Jellyfin at the Tailscale IP.
Jellyfin matches your files against its database to pull in posters, descriptions, and ratings. It relies on the filename and folder structure to identify what it's looking at. Messy filenames cause misidentification. Look at the potencial issues section below for examples of what to do if youy want a code to do it automatically.
โโโ Movies/
โ โโโ Inception (2010)/
โ โโโ Inception (2010).mkv
โโโ Shows/
โโโ Breaking Bad/
โโโ Season 01/
โโโ Breaking Bad S01E01.mkv
Rules
| Type | Rule | Example |
|---|---|---|
| Movies | Movie in its own folder with year | Inception (2010)/Inception (2010).mkv |
| TV Shows | Show โ Season folder โ S01E01 naming | Breaking Bad/Season 01/Breaking Bad S01E01.mkv |
| โ Avoid | Extra tags in filename | Movie.1080p.x265-GROUP[EZTVx].mkv |
1080p.HEVC.x265-MeGusta[EZTVx.to] in the filename confuses Jellyfin and causes it to misidentify seasons or episodes. Always rename to a clean format.Drive won't unmount ("target is busy")
Jellyfin or another process is holding the drive open. Stop Jellyfin first, then find and kill any remaining process using the drive.
Tailscale not reachable from outside
Make sure you're testing from a device that also has Tailscale installed and connected. The 100.x.x.x IP only works between Tailscale devices. Also verify Jellyfin and Tailscale are both running.
Port forwarding blocked (Double NAT)
If you have both a modem and a router, standard port forwarding won't work. Either call your ISP to enable bridge mode, or use Tailscale instead (recommended).
Drive shows as sda instead of sda after reboot
Sometimes after a reboot the drive gets assigned a different device name (sda instead of sda). This is fine since fstab uses the UUID not the device name โ just remount manually if needed:
Quick Reference โ Important URLs
| Purpose | URL / Address |
|---|---|
| Jellyfin (local network) | http://[YOUR-PI-IP]:8096 |
| Jellyfin (via Tailscale) | http://[YOUR-TAILSCALE-IP]:8096 |
| File transfer (Windows) | \\[YOUR-PI-IP] |
| Tailscale dashboard | https://login.tailscale.com |
- โ Raspberry Pi 5 running Raspberry Pi OS Lite (64-bit)
- โ 2TB external drive formatted ext4, auto-mounted at /mnt/media
- โ Jellyfin Media Server installed and running
- โ Samba network share for easy file transfers from PC
- โ Tailscale installed for secure remote access from anywhere
- โ Proper file naming convention for Jellyfin library matching
While this setup is solid, there are a few potential issues to be aware of:
If you want to expand your storage in the future, you can connect additional hard drives to the Pi using a powered USB hub โ one that plugs into the wall with its own power adapter. This is important because larger hard drives (especially 3.5 inch desktop drives) draw more power than the Pi can supply through its USB ports alone. A powered hub solves this by giving each drive its own power source.
If you want your files to have names like "Show Name S01E01.mkv", you'll need to rename them manually or use a script. And the seasons need to be in folders named "Season 01", "Season 02", etc. Otherwise Jellyfin will have trouble matching them to the correct show and season, and you might end up with missing posters or metadata. You can run:
Rename all episode files (run from the show folder on the Pi terminal):
Rename all season folders: