From: Igor Mammedov <niallain@gmail.com>
To: Jeremy Allison <jra@samba.org>
Cc: Steve French <smfrench@gmail.com>,
"Q (Igor Mammedov)" <qwerty0987654321@mail.ru>,
linux-fsdevel <linux-fsdevel@vger.kernel.org>,
linux-cifs-client@lists.samba.org
Subject: Re: dfs path construction fixup for / character in \\server\share component of dfs path
Date: Thu, 24 Apr 2008 12:04:06 +0400 [thread overview]
Message-ID: <48103EF6.7010004@gmail.com> (raw)
In-Reply-To: <20080423191906.GH10791@samba1>
Jeremy Allison wrote:
> On Wed, Apr 23, 2008 at 12:11:50PM -0700, Jeremy Allison wrote:
>> On Wed, Apr 23, 2008 at 06:28:39PM +0400, Igor Mammedov wrote:
>>> Steve French wrote:
>>>> Attached is dfs path construction fixup for / character in
>>>> \\server\share component of dfs path. Let me know if you see any
>>>> problem - but it gets Samba past the problem with not returning
>>>> STATUS_PATH_NOT_COVERED
>>>>
>>>> similar change will have to be made to build_full_dfs_path_from_dentry
>>>> in cifs_dfs_ref.c
>>>>
>>>> This makes it easier for me to test the remainder of the changes
>>>> needed to the SMB GetDFSReferral function(s). Has anyone checked on
>>>> the answer to Al's question on submount expiry from a few days ago?
>>>
>>> I've just tested it and the patch fixed a problem with the lack of
>>> STATUS_PATH_NOT_COVERED with unix-ext enabled on samba server.
>>> 1. samba with unix-ext enabled returns (5th packet) dfs link as a symbolic link,
>>> but for dfs code it should be the directory type so we could fix it in the time
>>> of creating inode and get the server generated inode number.
>>>
>>> No. Time Source Destination Protocol Info
>>> 1 0.000000 192.168.133.129 192.168.133.1 SMB Trans2 Request, QUERY_PATH_INFO, Query File Unix Basic, Path: //192.168.133.1/dfs/dfs2
>>> 2 0.000385 192.168.133.1 192.168.133.129 SMB Trans2 Response, QUERY_PATH_INFO, Error: STATUS_PATH_NOT_COVERED
>>> 3 0.000670 192.168.133.129 192.168.133.1 TCP 46662 > microsoft-ds [ACK] Seq=127 Ack=40 Win=1728 Len=0 TSV=509648098 TSER=3625842022
>>>
>>> 4 0.006911 192.168.133.129 192.168.133.1 SMB Trans2 Request, QUERY_PATH_INFO, Query File Unix Basic, Path: /dfs2
>>> 5 0.007110 192.168.133.1 192.168.133.129 SMB Trans2 Response, QUERY_PATH_INFO
>>>
>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ - here our chance to get it working
>>>
>>> 6 0.016002 192.168.133.129 192.168.133.1 SMB Trans2 Request, QUERY_PATH_INFO, Query File Unix Link, Path: /dfs2
>>> 7 0.016219 192.168.133.1 192.168.133.129 SMB Trans2 Response, QUERY_PATH_INFO
>>> 8 0.049621 192.168.133.129 192.168.133.1 SMB Trans2 Request, QUERY_PATH_INFO, Query File Unix Basic, Path: //192.168.133.1/dfs/msdfs:\172.16.61.1\dfs2
>>> 9 0.050706 192.168.133.1 192.168.133.129 SMB Trans2 Response, QUERY_PATH_INFO, Error: STATUS_OBJECT_NAME_NOT_FOUND
>>>
>>> Patches that make dfs working in this case are attached.
>> Thanks. I'm going to fix Samba 3.2 (not sure if this will make
>> final release) to return directory not symlink on QPATHINFO
Can try to do it, have 'v3-2-test' branch checked out already.
>
> Hmmmmm. Looking carefully that's the wrong thing to do.
>
> I think the client is doing the wrong thing here when it
> gets the STATUS_PATH_NOT_COVERED error. Shouldn't it then
> call TRANS2_GET_DFS_REFERRAL instead of doing a QPATHINFO ?
I'm doing the second call with a short path to get inode info
including server generated inode number. If not for the last
then second call could be omitted and inode be filled with fake
values and locally generated ino.
PS:
Windows server does not object against the second call and returns
info on the dfs junction point (as directory).
More uniform behavior between different implementations would be
better for all.
--
Best regards,
-------------------------
Igor Mammedov,
niallain "at" gmail.com
next prev parent reply other threads:[~2008-04-24 8:04 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-04-18 23:03 dfs path construction fixup for / character in \\server\share component of dfs path Steve French
2008-04-23 14:28 ` Igor Mammedov
2008-04-23 19:11 ` Jeremy Allison
2008-04-23 19:19 ` Jeremy Allison
2008-04-24 8:04 ` Igor Mammedov [this message]
2008-04-25 19:22 ` Jeremy Allison
2008-04-25 19:50 ` Jeremy Allison
2008-04-25 21:16 ` Jeremy Allison
2008-04-27 13:00 ` Igor Mammedov
2008-04-28 18:05 ` Jeremy Allison
2008-04-28 18:51 ` Jeremy Allison
2008-05-21 13:57 ` Igor Mammedov
2008-05-24 0:46 ` Jeremy Allison
2008-05-24 1:33 ` Steve French
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=48103EF6.7010004@gmail.com \
--to=niallain@gmail.com \
--cc=jra@samba.org \
--cc=linux-cifs-client@lists.samba.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=qwerty0987654321@mail.ru \
--cc=smfrench@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).