<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet href="http://bugs.horde.org/themes/feed-rss.xsl" type="text/xsl"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
 <channel>
  <title>MKDIR Regression with newer SAMBA versions</title>
  <pubDate>Fri, 29 Aug 2008 20:23:33 -0400</pubDate>
  <link>http://bugs.horde.org/ticket/5931</link>
  <atom:link rel="self" type="application/rss+xml" title="MKDIR Regression with newer SAMBA versions" href="http://bugs.horde.org/ticket/5931/rss" />
  <description>MKDIR Regression with newer SAMBA versions</description>

  
  
  <item>
   <title>Regression with gollem's SMB backend between SAMBA-3.0.24 an</title>
   <description>Regression with gollem's SMB backend between SAMBA-3.0.24 and 3.0.25c.

Problem with 3.0.25c and newer:
* Creating a folder &quot;folder2&quot; in ROOT/folder1 results in ROOT/folder1folder2 being created
* Creating a folder &quot;folder3&quot; in ROOT/folder1/folder2 results in ROOT/folder1/folder2folder3 being created

3.0.24 and lower work as expected.

Horde Framework: 3.1.4

The $dir and $mkdir variables in lib/VFS/smb.php's createFolder() are the same, regardless of the samba version:
Trying to create ROOT/temp/subdir1: $dir=/temp $mkdir=subdir1</description>
   <pubDate>Tue, 27 Nov 2007 05:42:50 -0500</pubDate>
   <link>http://bugs.horde.org/ticket/5931#t39069</link>
  </item>
  <item>
   <title>Further debugging yields:

The critical statement sent by </title>
   <description>Further debugging yields:

The critical statement sent by _command() in lib/VFS/smb.php:
/usr/bin/smbclient &quot;//1.2.3.4/sharename&quot; &quot;-p139&quot; &quot;-Uusername&quot; -D &quot;/temp&quot; -I 1.2.3.4 -c &quot;mkdir \&quot;subdir1\&quot;;&quot;

When fired from the command line this statement does what expected in samba-3.0.24 and misbehaves as described in the bugreport with samba-3.0.25c and higher.

SOLUTION:
Appending a backslash in the -D argument solves the problem FOR BOTH SAMBA VERSIONS:
/usr/bin/smbclient &quot;//1.2.3.4/sharename&quot; &quot;-p139&quot; &quot;-Uusername&quot; -D &quot;/temp/&quot; -I 1.2.3.4 -c &quot;mkdir \&quot;subdir1\&quot;;&quot; 

Will create a patch to smb.php soon.</description>
   <pubDate>Tue, 27 Nov 2007 05:55:14 -0500</pubDate>
   <link>http://bugs.horde.org/ticket/5931#t39070</link>
  </item>
  <item>
   <title>Honestly, this is really a bug in samba and I tend to not wo</title>
   <description>Honestly, this is really a bug in samba and I tend to not workaround that. It should be fixed in smbclient.</description>
   <pubDate>Tue, 27 Nov 2007 06:33:16 -0500</pubDate>
   <link>http://bugs.horde.org/ticket/5931#t39073</link>
  </item>
  <item>
   <title>I will bring up the issue on the samba mailing list and see </title>
   <description>I will bring up the issue on the samba mailing list and see what the devs intended. I remember reading something about an intended small smbclient syntax change a while ago but can't find it anymore.

Attached a workaround for the folder-creation problem. When patched, gollem properly creates folders with new AND old samba versions, so no harm in applying that one.

Also I found out that there are more operations which don't work after the samba upgrade. Deleting files f.ex. yields this error:
Cannot delete &quot;test.txt&quot;: &quot;/temp/test.txt&quot; is not a directory.

Don't have time for further investigation and patching now, but might return to it later.</description>
   <pubDate>Tue, 27 Nov 2007 09:05:06 -0500</pubDate>
   <link>http://bugs.horde.org/ticket/5931#t39075</link>
  </item>
  <item>
   <title>Attachment</title>
   <description>Attachment</description>
   <pubDate>Tue, 27 Nov 2007 09:07:16 -0500</pubDate>
   <link>http://bugs.horde.org/ticket/5931#t39076</link>
  </item>
  <item>
   <title>Topic on samba mailing list:
http://lists.samba.org/archive</title>
   <description>Topic on samba mailing list:
http://lists.samba.org/archive/samba/2007-November/136617.html</description>
   <pubDate>Wed, 28 Nov 2007 03:51:48 -0500</pubDate>
   <link>http://bugs.horde.org/ticket/5931#t39105</link>
  </item>
  <item>
   <title>topic is tracked back to the erroneous samba commit and now </title>
   <description>topic is tracked back to the erroneous samba commit and now waits for developer feedback.

Even if it gets fixed soon I propose you put a warning about the incompatibility in gollem's readme with a link to this ticket. Distros will carry the affected samba versions for some time and people will stumble over the issue.</description>
   <pubDate>Thu, 29 Nov 2007 14:39:55 -0500</pubDate>
   <link>http://bugs.horde.org/ticket/5931#t39160</link>
  </item>
  <item>
   <title>Since the change works in both versions I don't see a real r</title>
   <description>Since the change works in both versions I don't see a real reason not to apply it (though I'd fix the patch to not use a regexp when it really doesn't need it). I'll commit in a day or so if there's no negative feedback.

Is this perhaps the same issue with deleting? Any progress there?</description>
   <pubDate>Thu, 29 Nov 2007 17:11:32 -0500</pubDate>
   <link>http://bugs.horde.org/ticket/5931#t39163</link>
  </item>
  <item>
   <title>Attached an updated patch which superseedes the old one. Imp</title>
   <description>Attached an updated patch which superseedes the old one. Improvements:
* also fixes file deletion and recursive folder deletion
* doesn't use rexexps any more

The patch passed the following tests on both samba-3.0.24 and 3.0.27a:
* create root level folders
* create subfolders
* create files in subfolders
* delete files in subfolders
* delete folder with subfolders and files in those subfolders

While I'm using it in production now I recommend you give it a bit of testing with other samba versions and environments as I cannot do that.</description>
   <pubDate>Fri, 30 Nov 2007 02:56:20 -0500</pubDate>
   <link>http://bugs.horde.org/ticket/5931#t39170</link>
  </item>
  <item>
   <title>Committed an equivalent patch to HEAD (will be in the next H</title>
   <description>Committed an equivalent patch to HEAD (will be in the next Horde 3.2 RC):
http://lists.horde.org/archives/cvs/Week-of-Mon-20071126/072815.html

Thanks!</description>
   <pubDate>Fri, 30 Nov 2007 15:42:30 -0500</pubDate>
   <link>http://bugs.horde.org/ticket/5931#t39209</link>
  </item>
  

 </channel>
</rss>
