Enable SAMBA server
From AwkwardTV
Contents[hide] |
[edit] Introduction
SAMBA is an ethernet based service wich allows to share files and printers.
This how-to bases on the AwkwardTV forum SMB in reverse.
[edit] Prerequisites
This method bases on the installation via SSH. Following this method, the extracting and editing commands will work directly on the AppleTV.
[edit] Installation
The installation bases on the MacPorts project and its Samba package. The idea is to install a SAMBA service on an Intel Mac and copy it to the AppleTV. Luckily, you won't have to do this yourself, as the result is downloadable.
- Copy it to your AppleTV via
scp
or Fugu to/Users/frontrow/Documents/
.
- Extract it:
ssh frontrow@AppleTV.local
sudo -s
tar -xvjpf /Users/frontrow/Documents/samba3_macports_bin.tar.bz2 -C /
[edit] Configuration
[edit] Configuration file
The server configuration is found in /opt/local/etc/samba3/smb.conf
.
Edit it:
cp /opt/local/etc/samba3/smb.conf.sample /opt/local/etc/samba3/smb.conf
nano -w /opt/local/etc/samba3/smb.conf
Editing the configuration can be a tedious process. The simplest thing to do is to modify the proper part in order to have:
[homes]
comment = Home Directories
browseable = yes
writable = yes
[edit] Password
The SAMBA passwords are different from the user login ones. Give the user frontrow
a password:
/opt/local/bin/smbpasswd -a frontrow
[edit] Service
The service is now ready to be started:
/opt/local/sbin/smbd -c /opt/local/etc/samba3/smb.conf
/opt/local/sbin/nmbd -c /opt/local/etc/samba3/smb.conf
Test if from your Mac's Finder menu: Go -> Connect to Server... (Cmd-K)
, give the server address smb://AppleTV.local
and follow the indications.
The chosen directories are mounted on /Volumes/
. You can unmount them from there, either from the Finder or from the Terminal.
[edit] Automatic loading at boot
Automatically loading the Samba service at boot can be done with the help of /etc/rc.local
. Create or edit the file and add the commands from the following listing:
# rc.local
# start the SAMBA service
/opt/local/sbin/smbd -c /opt/local/etc/samba3/smb.conf
/opt/local/sbin/nmbd -c /opt/local/etc/samba3/smb.conf
Unmount the Samba shares, restart the AppleTV and try mounting them again.
1 comment:
muito bom kra,
Post a Comment