[Samba] Deletion of directory symlink via Samba deletes files in original subdirectory on Unix

Kathy banshee135 at gmail.com
Mon Nov 30 11:07:10 MST 2009


I just confirmed that this problem exists on all our Samba servers,
irregardless of version. Here is an example of how I'm testing it:

On Unix SERVER I have a directory called /testdir/kathytest and inside
of kathytest are file1, file2, and file3  Testdir is a Samba exported
directory on SERVER.

I create a soft link in /testdir to point to kathytest:  ln -s
./kathytest ./testlink

So now if I go to /testdir/testlink it will take me to
/testdir/kathytest and I'll see file1, file2, and file3.

Now, in Samba I go to  \\SERVER\testdir and I see both the softlink
testlink and my directory kathytest.

Through Samba I delete \\SERVER\testdir\testlink.  It then asks me
from the Windows side "Are you sure you want to remove the folder
`testlink' and all its contents?".

I say yes and it deleted the "testlink" symlink and deletes file1,
file2, and file3 inside of kathytest.  The subdir kathytest does not
get deleted, however.

This happens on both ext3 and zfs exported filesystems, so it's not
just limited to ZFS.



On Mon, Nov 30, 2009 at 9:27 AM, Kathy <banshee135 at gmail.com> wrote:
> Actually, that is only one of our servers.  We have multiple Samba
> servers running here and it's possible that the folks are pointing at
> the 3.0.25a version our Solaris 10 ZFS server.  The other possible
> server is version 3.0.33 running on RHEL 4.   I know for a fact that
> the 3.0.25a version does it as I tested it out myself.
>
> Kathy
>
>
>
> On Mon, Nov 30, 2009 at 9:23 AM, Kathy <banshee135 at gmail.com> wrote:
>> My apologies for not getting back to you until now about this.  Was
>> out due to the holidays.  We are using version 3.2.8 on RHEL 5.2.
>>
>> Kathy
>>
>>
>>>> >What version of Samba ?
>>>> >
>>>> >Jeremy
>>>> This sounds a bit like the problem we (EditShare) discovered and
>>>> that  you patched a few years ago-- in the 3.0.14 days I think.
>>>> Remember... We discovered a sort of delayed reaction.  If you
>>>> deleted a symlink to a file that some other user had open, when both
>>>> users finally closed the file the FILE would get deleted rather than
>>>> the SYMLINK.
>>>>
>>>> Could it be related?
>>>
>>> Maybe, it could *be* that problem, if the version they're running
>>> is old enough (which is why I asked :-).
>>>
>>> Jeremy.
>>> --
>>> To unsubscribe from this list go to the following URL and read the
>>> instructions:  https://lists.samba.org/mailman/options/samba
>>>
>>
>


More information about the samba mailing list