mount.cifs错误(2):使用前缀路径时没有这样的文件或目录


11

我尝试了以下命令:

mount -t cifs //server/share/directory /mnt/directory -o credentials=/path/to/cifs.credentials --verbose

响应是:

mount.cifs kernel mount options: ip=<IP of server>,unc=\\server \share,user=<username>,prefixpath=directory,pass=********
mount error(2): No such file or directory
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)

但是,如果我尝试不带前缀路径的相同命令:

mount -t cifs //server/share /mnt/directory -o credentials=/path/to/cifs.credentials --verbose

它有效,并且我可以访问/ mnt / directory / directory。

如果我在选项中明确指定了前缀路径,则会出现相同的错误,即:

mount -t cifs //server/share /mnt/directory -o credentials=/path/to/cifs.credentials,prefixpath=directory --verbose

附加信息:

  • 我可以使用连接到所需的路径 smbclient //server/share -U username -W domain -D directory
  • mount.cifs版本:5.5
  • Debian内核3.2.0-4-amd64
  • 我能够在Debian内核2.6.32-5-amd64上使用mount.cifs版本4.5连接到另一台机器上

有什么想法为什么前缀路径似乎会引起问题?这条路最近一直在起作用。我怀疑Linux方面对软件包的更新或Windows更新是新行为的背后。


这是NAS吗?当您说您尝试“不带前缀路径”时,命令看起来相同。那是错字吗?
章鱼

到NetApp SAN。您是对的,那是一个错字-我已经纠正了。
cherdt 2014年

NetApp支持技术已经提供了数据包跟踪,他们发现mount.cifs正在发送// server / share //目录,而不是// server / share / directory。这似乎是问题的原因(尽管不是解决方案)。
彻德2015年

Answers:


6

最终找到了与我们的NetApp一起使用的此问题的解决方法。如果不需要DFS,请尝试使用该nodfs选项进行安装。

mount -t cifs //server/share/directory /mnt/directory -ocredentials=/path/to/cifs.credentials,nodfs

我们还使用netapp。感谢您的解决方法,它节省了我的下午时间。
Danduk82
By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.