Configure your linux box to be a Mac file server using netatalk afpd and avahi-daemon
This install was done on a Fedora 11 system
Install Netatalk Afpd and Avahi-Daemon
yum install netatalk avahi |
Configure Appletalk Netatalk
vi /etc/atalk/afpd.conf |
Add the following to the end of the file:
- -noddp -tcp -uamlist uams_randnum.so,uams_dhx.so,uams_dhx2.so -nosavepassword -advertise_ssh |
Configure Netatalk to only start the services we need
vi /etc/atalk/netatalk.conf |
Change the following values:
ATALKD_RUN=no PAPD_RUN=no CNID_METAD_RUN=yes AFPD_RUN=yes TIMELORD_RUN=no A2BOOT_RUN=no |
Configure Netatalk to share our folders
vi /etc/atalk/AppleVolumes.default |
Syntax:
allow: users and groups allowed to access share rwlist: users and groups allowed read and write access Changeto your users separated by commas jim.bob.doug Change <@group> to your groups separated by commas @accounting, @marketing (keep the @ infront of the group name) * Users and Groups must already exist in Linux Add for Users Home Folders: ~/ "$u" allow: rwlist: ,<@group> cnidscheme:cdb Add a folder: /home/folder allow: ,<@group> rwlist: ,<@group> cnidscheme:cdb options:usedots,upriv
Configure Avahi and mDNS (linux version of bonjour)
We need to configure Avahi and mDNS so the Mac computers on the network can find our Appletalk file server
We need to create a service file for our afpd service:
vi /etc/avahi/services/afpd.service |
Add the following:
<?xml version="1.0" standalone='no'?> <!DOCTYPE service-group SYSTEM "avahi-service.dtd"> <service-group> <name replace-wildcards="yes">%h Xserve</name> <service> <type>_afpovertcp._tcp</type> <port>548</port> </service> <service> <type>_device-info._tcp</type> <port>0</port> <txt-record>model=Xserve</txt-record> </service> </service-group> |
Add mDNS to nsswitch
vi /etc/nsswitch.conf |
Add mdns to the line hosts:
hosts: files dns mdns |
Configure Appletalk to start at system startup
chkconfig atalk chkconfig avahi-daemon |
Start Appletalk and Avahi (Bonjour)
service atalk start service avahi-daemon start |
Open Firewall Ports
port: 548 tcp
Check that Netatalk service started properly:
nbplkup |
localhost:AFPServer 65280.31:128 "localhost:netatalk" 65280.31:4 "localhost:Workstation" 65280.31:4 |
Related content:
