| SAMBA Tutorial |
|
|
|
| Written by macsat | |
| Friday, 25 November 2005 | |
|
NOTE!! While this tutorial WILL give you what it promises, it sure could use some updates - nmbd should be added for example! Please consider donating some euros using PayPal, as I need a second ASUS Device for creating Oleg tutorials (at the moment I have 1 Asus WL-500g Deluxe only - running OpenWrt).
This is a step for step guide for adding a Windows Shared Folder / Shared Drive on your ASUS WLxxxx linux-based wireless product.
ASUS WL-HDD
If you are the lucky owner of any of the above devices, you have come to the right place. After following the steps in this guide, your ASUS WL device will have all its normal functionality, and also enable you to share a folder on an attached USB Hard Drive or USB Flash Device to your local network. Even though the ASUS WL-500g Deluxe only has a fairly small CPU (200mzh) and a limited amount of memory (32MB), SAMBA performs pretty well for me. I am using my ASUS WL-500gx to stream movies to my Xbox using SAMBA, and I have no dropouts at all, even with movies with quite high bitrates. Tutorial Index1. Prerequisites - What is needed to get started.2. Configuring SAMBA When creating the start-up script at the end of this Tutorial, I consider your setup to be simular to the setup I created in the ipkg Tutorial PrerequisitesAll you need is :Configuring SAMBAIn order to run SAMBA there is nothing to be installed on your router. SAMBA is included in Olegs great firmware. I have decided NOT to use the web-interface for setting up the SAMBA service, but rather use a small simple config file. I created the config file with inspiration from several posts in the forums at Chupa.nl, and found that this simple version works very well for me. First create a subfolder to /opt/etc/ called samba :
mkdir /opt/etc/samba < enter >
Create the configuration file in this directory, using nano or any other editor of your choice:
nano /opt/etc/samba/smb.conf < enter >
The file should end up looking like this :
[global]
workgroup = Your_Workgroup guest account = nobody security = share browseable = yes guest ok = yes guest only = no log level = 1 max log size = 100 encrypt passwords = yes dns proxy = no
socket options = TCP_NODELAY IPTOS_LOWDELAY SO_KEEPALIVE SO_SNDBUF=8192
force user = admin [smbshare1] path=/opt/share/samba1 writeable = yes browseable = yes [smbshare2] path=/opt/share/samba2 writeable = yes browseable = yes You should change "Your_Workgroup" to the name of your choice in your Windows network. Also you can change the names [smbshare1] / [smbshare2] to something that makes sense considering the content of the folder. As you see in the above config file, I have created a subfolders called /opt/share/samba1 and /opt/share/samba2. You can share any folder in this way, and make as many shares as you like in the same fashion as the above two. All that is left now is making SAMBA start at boot. Create a SAMBA init file :
nano /opt/etc/init.d/S97Samba < enter >
The file should be something like :
#!/bin/sh
/usr/sbin/smbd -D -l /opt/var/log/smbd.log -s /opt/etc/samba/smb.conf
/usr/sbin/nmbd -D -n myasus -o -l /tmp -s /opt/etc/samba/smb.conf
Now make the file executable :
chmod 755 /opt/etc/init.d/S97Samba < enter >
Now try to reboot your router, and see if the SAMBA server is up :
ps |grep "smb" < enter >
You should see some output containing something like this :
504 S /usr/sbin/smbd -D -l /opt/var/log/smbd.log -s /opt/etc/samba/smb.conf
Now you should be able to access your share from any Windows machine on your network, and any other device that supports SAMBA / Windows Networking Client mode. I hope you found this tutorial useful. |
|
| Last Updated ( Tuesday, 08 May 2007 ) |
| < Prev | Next > |
|---|







