小编Ser*_*gey的帖子

如何对 Linux 内核中的 dns_resolver 进行故障排除

Linux 提供了一种工具,让内核及其模块依靠用户空间工具来解析 DNS 名称。例如,CIFS 使用它来支持 DFS 中的推荐。

我看到的问题是我无法让内核解析特定的 DNS 名称,我不明白它为什么会失败。

为了了解根本原因,我通过运行以下命令在 CIFS 和内核 dns 解析器中启用了调试输出:

echo "1" >  /sys/module/dns_resolver/parameters/debug  # dns_resolver
echo "7" > /proc/fs/cifs/cifsFYI  # CIFS
Run Code Online (Sandbox Code Playgroud)

这是发生故障时我在 dmesg 中看到的内容:

fs/cifs/cifs_dfs_ref.c: DFS: ref path: \ESOTEST\dfstest\FS_SERV
fs/cifs/cifs_dfs_ref.c: DFS: node path: \FS\FS_SERV
fs/cifs/cifs_dfs_ref.c: DFS: fl: 2, srv_type: 0
fs/cifs/cifs_dfs_ref.c: DFS: ref_flags: 0, path_consumed: 24
fs/cifs/netmisc.c: address conversion returned 0 for FS
fs/cifs/netmisc.c: address conversion returned 0 for FS
[ls    ] ==> dns_query((null),FS,2,(null))
fs/cifs/dns_resolve.c: dns_resolve_server_name_to_ip: unable to resolve: FS
fs/cifs/cifs_dfs_ref.c: cifs_compose_mount_options: Failed to …
Run Code Online (Sandbox Code Playgroud)

linux server-message-block cifs dfs

6
推荐指数
1
解决办法
3314
查看次数

标签 统计

cifs ×1

dfs ×1

linux ×1

server-message-block ×1