Subject: [netatalk-admins] netatalk and samba cooperation

From: "Philip S. Wachtel" <[email-masked]>
Date: Wed, 07 Jan 1998 08:58:53 -0500

Hello,

I'm using netatalk and samba to export a shared volume to both pcs and
macs.  Things are working well, but I do have two questions.

1. If a Mac user puts something on the volume and a PC user deletes or
moves it, files are left in the .AppleDouble and I think in the
.AppleDesktop as well.  Does anyone know how to keep things straight under
these conditions?

2. Does anyone know of a way of setting a default group like "users" for
this shared netatalk volume?

Thanks very much!

Philip

---

From: Vivek <[email-masked]>
Date: Wed, 7 Jan 1998 14:18:27 +0000 (GMT)

> .AppleDesktop as well.  Does anyone know how to keep things straight under

Off the top of my head, you could write a script to prune orphaned
.AppleDouble entries, [I believe someone on the list already did this],
and run that from time to time, or via cron, or at boot-time, or when the
moon is gibbous[you get the idea :)], or you could compile the hfs module
with the tweak for sharing via netatalk, and export the whole hfs 
partition.

--
fsck -f -b 8193 /dev/cortex

---

From: "Philip S. Wachtel" <[email-masked]>
Date: Thu, 08 Jan 1998 15:16:38 -0500

Hey!  Thanks for the advice.  I've been trying to figure out how to
construct such a script, but I'm falling short.  Could you by any chance
give me an example or tell me where I can find the one that was already
done?  I would really appreciate it.  I have a bunch of users on this thing
and the .Apple* files are scaring me. :-)

Thanks very much!

Philip

---

From: Andrew McNabb <[email-masked]>
Date: Thu, 8 Jan 1998 19:49:19 -0600

It seems to me that it wouldn't be very difficult to write a samba patch
that is netatalk friendly.  It could keep track of appledouble, special
characters in filenames, etc.  I'm not good enough at programming, but I
would appreciate it if such a patch were available.

-------------------------------
         Andrew McNabb            I am an International Arms Trafficker!!!!!
      Argus Systems Group       http://online.offshore.com.ai/arms-trafficker/
   [email-masked]
-------------------------------

---

From: Edan Idzerda <[email-masked]>
Date: Thu, 8 Jan 1998 21:31:27 -0500 (EST)

> would appreciate it if such a patch were available.

I think this seems like a more efficient solution than runing some
nasty cron job, though I suppose it would cost you an extra stat() or
two for every unlink().  As a per-share option it would probably be
fine, though.  I might look at doing this because I think it would be a
nice addition to their coexistence--though in a race I'm sure Jeremy
Allison could beat me.   :)  (Apologies if I spelled his named wrong.)

- edan

--
Edan Idzerda	<[email-masked]>
System Administrator --  Michigan Technological University, Houghton MI USA

---

From: Bill Peck <[email-masked]>
Date: Fri, 16 Jan 1998 08:47:05 -0500 (EST)

This would also fix problems of pc users moving or renaming a file and the mac
loosing the resource fork...  My company would pay a nice shareware fee if
Samba and netatalk worked with each other!! :-)

What was this talk of the hsf module?  Also does anyone know if netatalk would
handle resouce forks from an hfs mounted filesystem?  Or is that what someone
was saying?  We have some Mac Clip art cd's that we would love to share via
netatalk...

> Allison could beat me.   :)  (Apologies if I spelled his named wrong.)

----------------------------------
E-Mail: Bill Peck <[email-masked]>
Date: 16-Jan-98
Time: 08:44:12

This message was sent by XFMail
----------------------------------

---

From: Vivek <[email-masked]>
Date: Fri, 16 Jan 1998 14:00:26 +0000 (GMT)

You can compile the hfs module to be 'netatalk-friendly':

>From the hfs module docs [bits cut out]:

  If included in the options, then the behavior of the filesystem is
  changed to make it fully read-write compatible with Netatalk's afpd.
  In this mode you should not use normal user-level tools to modify the
  filesystem, though reading from it is acceptable.  This is because the
  return codes from some system calls are changed to fool afpd.  These
  changes will confuse many user-level tools.  In particular ``rm -r''
  will loop forever.
  .
  .
  You will probably want to use the uid=, gid= and umask= mount options.
  Note that because all the files on an HFS filesystem belong to a
  single user and group and have a single umask, the full AppleShare
  permission scheme will not work through Netatalk.
  .
  .
  This mode is known to be compatible with afpd from Netatalk versions
  1.4b1 and 1.4b2, and known to be incompatible with the afpd from
  version 1.3.3.  As of this writing Netatalk version 1.4 has not yet
  been released.  However, it is expected that this mode will be
  compatible with afpd from Netatalk version 1.4 when it is released.

So it looks like there are still lots of 'issues' to be cleared up. My
copy [version 0.95, 28 Apr 1997] may well be out of date. And no, I've
never tried it. Any guinea pigs out there? :)

---

From: Chris Albone <[email-masked]>
Date: Mon, 16 Mar 1998 17:36:28 +1100

> would appreciate it if such a patch were available.

I've got the beginnings of such a beast here. Currently, we are running CAP and
Samba together & we face much the same sort of problem as the folks that run
Netatalk and samba.  I've hacked at samba a bit so that it knows to create the
hidden directories that CAP uses. I also have some (as yet, untested) code that in
theory should do the same for a NetAtalk share.

I have not investigated the netatalk code very much, so I am at a loss as to how
to handle moving and copying of Mac applications under samba. Specifically, I am
not entirely sure how to make samba become aware of .AppleDesktop.

If there is sufficient interest, I might clean up the patches and send them out to
you guys to hack away at.

Chris