Simple PiNAS a Raspberry Pi Guide

Pi NAS Raspberry Pi Setup Guide

Got an old Raspberry Pi gathering dust and a spare hard drive lying around? Let’s turn them into something useful – your very own Network Attached Storage (NAS) system! This simple project will give you a convenient way to share files across all the devices in your home network.

What You’ll Need:

  • A Raspberry Pi 4
  • A USB hard drive (I’m using a Western Digital Elements drive)
  • Your home network connection

Let’s dive into the setup process!

Step 1: Prepare Your System First things first, let’s make sure our Raspberry Pi is up to date. Open up your terminal and run:

sudo apt-get update
sudo apt-get upgrade

This might take 10-15 minutes if you haven’t updated in a while, but it’s worth the wait!

Step 2: Install Samba We’ll be using Samba to share our files across the network. Install it by running:

sudo apt-get install samba samba-common

Step 3: Configure Your Share Now comes the fun part – setting up your shared folder! We’ll need to edit Samba’s configuration file. Open it using:

sudo vim /etc/samba/smb.conf

Add these lines at the bottom of the file:

[shared]
path = /media/pi/elements/shared
writeable = yes
browsable = yes
create mask = 0777
directory mask = 0777
public = no

Step 4: Create a Samba User For security, let’s set up a dedicated user account for accessing your NAS:

sudo smbpasswd -a pi

You’ll be prompted to enter and confirm a password. Remember this – you’ll need it to access your shared folders!

Step 5: Restart Samba To make all our changes take effect, restart the Samba service:

sudo systemctl restart smbd

You can verify everything’s running smoothly with:

sudo systemctl status smbd

Step 6: Connect to Your NAS Now for the moment of truth! From any computer on your network, you can connect to your NAS using:

  • On Mac: Go to Finder → Go → Connect to Server and enter: smb://[your-pi-hostname]/shared
  • On Windows: Open File Explorer and enter \[your-pi-hostname]\shared in the address bar

Enter your Pi username and password when prompted, and voilà! You’ve got yourself a working NAS!

Testing Your Setup Try creating a simple text file and copying it to your shared folder. If you can see and open it from both your Pi and your computer, congratulations – your NAS is working perfectly!

And there you have it – your very own NAS system running on a Raspberry Pi! It’s amazing what you can do with these little computers, isn’t it? This setup is perfect for sharing files across your home network, backing up important documents, or even hosting a media server.

Have you tried setting up a Raspberry Pi NAS before? What are you planning to use yours for? Let me know in the comments below!

Happy tinkering! 🚀

No Tag

No Responses

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.