Wednesday 13 January 2010

How to build your own NAS – Part 3


Now that you have familiarized yourself with your Ubuntu Linux box, let's get the NAS bit to work!

To start, you need to install Samba (no, not the Brasilian music style) and configure it. To accomplish this log in with your username and password and go to the "Accessories" menu on the desktop and open a "Terminal" session. You now need to switch to the Administrator account by typing the following in the Terminal windows:


sudo bash

When prompted, type in your password (this is the same password for your user).

We can now start the installation of Samba, by typing:

apt-get install samba samba-common

When the installation is finished you need to configure Samba to share a directory on your Ubuntu Linux system with the whole network. To configure Samba you need to edit a text file called smb.conf using one of the available text editors in Linux. You can use nano or a GUI text editor like gedit. If you choose to use gedit make sure you login to gedit as Administrator or the files will be read-only. Go to the Terminal window and type:

nano /etc/samba/smb.conf

This is what you need to add to the bottom of the file:

[nas]
path=/srv/nas
available=yes
browsable=yes
public=yes
writeable=yes

I used "/srv/nas" as the directory location for the NAS files, but this depends on what name you gave to the mount point of your data disk.

Now you need to make a change to another line, search for "Workgroup" and change the field to the name of your own Windows network. Save and close the file.

You should now be able to see the new shared folder on your Windows machines, in the Network Neighbourhood or just Network in Windows 7.

If all this command prompt stuff sounds too complicated and you really want to manage your Samba installation from a graphical interface, all you need to do is install Webmin on your Linux box, and that will allow you to manage most of your Linux servers from a web browser on any computer in your network.

One thing I haven't mentioned yet is that you need to connect your Linux machine to your router by either using a network cable or wirelessly if you installed a wireless network card.

On the next part of the series I'll guide you through installing and using Webmin.

No comments:

Post a Comment