Hello all,
In this guide I’ll show you, step by step, how to turn an old Raspberry Pi into a Network Attached Storage (NAS) box and local media server using Samba and Jellyfin. Your Pi won’t bake you a pie, but it’ll serve up your movies and files just fine!
Why I Built a NAS
I had:
- An old Raspberry Pi (Model 3 B+)
- A lonely external HDD gathering dust
I wanted to learn more about networking, reuse my hardware, and never let good tech go to waste.
Requirements
- Raspberry Pi (3 B+ or newer)
- SD card (≥ 32 GB) with reader
- Stable 5 V/3 A power supply & quality cable
- External HDD (I used a 2 TB drive)
- PC or laptop (Windows, Linux or macOS)
Step 1: Flash Raspberry Pi OS
- Download Raspberry Pi Imager from raspberrypi.org.
![[Pasted image 20250626051143.png]] - Choose Raspberry Pi OS Lite (headless) for minimal overhead.
- Select your SD card and write the image.
- You can press
ctrl+shift+xin the imager and set hostname login password and also configure ssh it would be very useful if you dont have an external monitor. - Click next and write the changes to the SD card.
- Eject the SD card and place it into the Raspberry Pi.
Step 2: First Boot & Network Access
- Insert the SD card, connect Pi → router (Ethernet) or Wi-Fi, then power on.
- You can see the Pi’s IP address directly from your router page if the router doesnt support it then connect the raspberrypi to a monitor or TV via HDMI and follow the steps below. - Find its IP:
hostname -I - SSH in:
ssh pi@<PI_IP> # Default password: raspberry - Update packages:
sudo apt update && sudo apt upgrade -y
Step 3: Mount Your External HDD
- (Optional) Install NTFS support if your drive is NTFS:
sudo apt install ntfs-3g -y - Plug in the HDD, then check its device name and UUID:
lsblk -f sudo blkid /dev/sda1 - Create mount point and edit
fstab:Add a line (replacesudo mkdir /mnt/hdd sudo nano /etc/fstab<UUID>with your drive’s UUID, adjustntfs-3gorext4):UUID=<UUID> /mnt/hdd ntfs-3g defaults,noatime 0 2 - Mount it:
sudo mount -a ls /mnt/hdd
Step 4: Set Up Samba (Windows-Friendly NAS)
- Install Samba:
sudo apt install samba samba-common-bin -y - Create a Samba user (will mirror your Linux
piuser):sudo smbpasswd -a pi - Edit share config:
Append at the end:
sudo nano /etc/samba/smb.conf[NAS] path = /mnt/hdd browseable = yes read only = no guest ok = no create mask = 0664 directory mask = 0775 - Restart Samba:
sudo systemctl restart smbd - From Windows Explorer, go to
\\<PI_IP>\NAS, enter your Samba credentials, and voilà!
Step 5: Install Jellyfin (Your Personal Netflix)
- Add Jellyfin’s repo and key:
sudo apt install -y apt-transport-https gnupg2 curl -fsSL https://repo.jellyfin.org/debian/jellyfin_team.gpg.key \ | sudo gpg --dearmor -o /usr/share/keyrings/jellyfin.gpg echo "deb [signed-by=/usr/share/keyrings/jellyfin.gpg] \ https://repo.jellyfin.org/debian \ $(. /etc/os-release && echo $VERSION_CODENAME) main" \ | sudo tee /etc/apt/sources.list.d/jellyfin.list sudo apt update - Install Jellyfin:
sudo apt install jellyfin -y - Enable & start the service:
sudo systemctl enable --now jellyfin - In your browser, navigate to
http://<PI_IP>:8096and follow the setup wizard.- Point Jellyfin’s media library to
/mnt/hdd/YourMediaFolder.
- Point Jellyfin’s media library to
Final Thoughts
– Keep your Pi cool (a heatsink helps).
– Use your router’s DHCP reservation for a stable IP.
– Back up configs if you get too adventurous.