Sometime ago Maryna's computer died, since then she has been wanting to recover the music off of her hard drive (which wasn't the cause of the failure). Now that the semester is over, and I have some breathing room, I found the time to do the recovery last night. Going in, the plan was to hook up the HD to my linux box, mount the drive, and setup a Samba share for it. Then, as I was flipping through the administration manual for SuSE 8.2 looking for some tips on setting up Samba, I noticed that SuSE comes with an AFP daemon already setup in the kernel... so the plan changed.

After getting the hard drive mounted, I took 5 minutes and setup netatalk. The version that came with SuSE 8.2 was 1.6.x, which worked great. I found setting up shares, and setting the permissions on those shares to be much easier than setting up a Samba share.

Case and Point

The syntax for setting up a share in Samba looks like this:

[public]
path = /usr/public
public = yes
only guest = yes
writable = yes
printable = no
That is pretty busy, requiring multiple lines, and I much preferred the setup of the netatalk daemons. To setup a share you edit AppleVolumes.default which looks like this:
/music "Music on Praxis" rwlist:@users
That's it, /music directory gets shared with the name Music on Praxis. The best part is that AFP for linux uses a PAM module - so you don't have to setup a Samba passwords for the users, they automatically use their unix passwords. To allow guest read access:
/music "Music on Praxis" rwlist:@users rolist:@guests
Where @guests represents a group called guests on the linux box. So perhaps the only advantage of using Samba is that the windows users don't have to have an account on the linux machine to access the drives, but as far as I understand it, there is a way to setup anonymous shares as well... so then again...

This is great! I was considering hooking up my printer to the linux server and setting up a Samba share, but I was concerned that it would take forever and a day to setup and that my Mac might not be able to print to it correctly. Now I'm going to play around with papd, a daemon for Apple Printer Sharing, that comes with netatalk. I think that it will work nicely.

I've noticed only a few bugs with the service. Most notably some users have trouble viewing files in the shared drive, but they can view their home directories (setup by default in SuSE 8.2) without any issues. I would assume that this is a configuration issue, but then it was good enough to recover Maryna's data files and tear down *grin* The only other thing that annoyed me was that the version of netatalk that I have doesn't do the Rendezvous (mdns) thing. So the share doesn't show up when you browse the network, but works fine when you specifically connect to it. I was going to setup HOWL to advertise the service for me (just for fun) but I don't have apt-get on the machine at this point, and the machine can't stay on the network all the time right now because of the wiring in the house (the wireless AP & hub are in the living room, whilst the servers are usually in the office, a good 40 feet away - and running cable isn't an option)

So not a serious comparison here, but that's my two cents anyway: netatalkd's syntax is better than Samba's... now if only windows machines could access Apple shares. *grin* Apple can access Microsoft shares, that should tell you something about who is more compatible.

 

Add to My Yahoo!

Add to Google

Subscribe with Bloglines

Austin Gilbert/Male/26-30. Lives in United States/Oklahoma/Tulsa/Midtown, speaks English. Spends 40% of daytime online. Uses a Fast (128k-512k) connection. And likes computer science/photography.
This is my blogchalk: United States, Oklahoma, Tulsa, Midtown, English, Austin Gilbert, Male, 26-30, computer science, photography.

Atalkd is much easier than Samba
2004/05/16