Make a raspberry pi file server.

In this post I will teach you how to create a Samba share on your Raspberry pi, this means that you will be able to access it from any device!
What you will need to have.

– a raspberry pi with wifi access

– a keyboard to type commands

– fun!


The setup

So first of all, you should have any version of Raspbian installed on your Raspberry pi. 

Let’s make a folder first, this will be the folder that we can access from our other devices. Just type:

mkdir foldername

Now open up a terminal and type:

sudo apt-get install samba samba-common-bin

Press Y on your keyboard when asked to.

Now we are going to edit the configuration file. To do this, simply type:

sudo nano /etc/samba/smb.conf

You will see a bunch of text, search for “wins support = no” and change the “no” to “yes” like this:

wins support = yes

Now scroll all the way to the bottom of the file and add the following:

[Folder name]

 comment= My shared folder

 path=/home/pi/foldername

 browseable=Yes

 writeable=Yes

 only guest=no

 create mask=0777

 directory mask=0777

 public=Yes

Now press CTRL+X, type y and press enter to save and exit. Now to set the password type:

smbpasswd -a pi

And then enter the password you want to use.

Now reboot the pi and you can access the folder from any device! In Windows, just go to file explorer and then network.

Advertisements

2 thoughts on “Make a raspberry pi file server.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s