Each time I install (or reinstall/reformat) a development server of my own I install Samba instead of any FTP server as I use Windows as my development platform and prefer to simply network the remote folder. Here is a quick how-to on setting up Samba and sharing a folder.
First we need to install Samba, either do this with your distributions package manager (it will be called either samba or smb) or download the latest release from the Samba website.
Once installed create a new user on your system by typing
# adduser <username>Note: This step is optional, if you already have a user and their directory you wish to share you should skip the previous step and replace “smb-test” with your users username and “/home/smb-test” with their home directory also.
Now edit smb.conf and append the following lines to the end of the file.
[my-share] path = /home/smb-test browseable = yes writeable = yes valid users = smb-test
Save and close the file. Now at the shell prompt enter this command
# smbpasswd -a smb-testNote: If your system cannot find the smbpasswd command try searching for smbpasswd on your machine and giving it the direct path like so
# find / | grep smbpasswd # /usr/local/bin/smbpasswd # /usr/local/bin/smbpasswd -a smb-test
Enter your desired password to access the share.
Lets restart the Samba server for changes to take affect.
# /etc/init.d/samba restartNote: This command is for Debian based distributions, your systems command may be different to restart the Samba service.
Now you should be able to access your Samba share in your desired operating system. For Windows users either goto My Network Places or try Start > Run and type in “\\<domain/ip of Samba host>”.









0 Comments until now
Add your Comment!