diff options
author | David Voit <david.voit@gmail.com> | 2024-04-03 07:24:48 +0200 |
---|---|---|
committer | Pavel Shilovsky <pshilovsky@samba.org> | 2024-04-28 00:00:12 +0000 |
commit | c6bf4d9a59809fbb0c22ef9eb167c099ab8089fb (patch) | |
tree | 9086346733731671d164c73131f1d3467d7022c6 /mount.cifs.c | |
parent | 4718e09e4b15b957bf9d729793bc3de7caad8134 (diff) | |
download | cifs-utils-for-next.tar.gz cifs-utils-for-next.tar.bz2 cifs-utils-for-next.zip |
Implement CLDAP Ping to find the closest sitefor-next
For domain based DFS we always need to contact the domain controllers.
On setups, which are using bigger AD installations you could get random dc on the other side of the world,
if you don't have site support. This can lead to network timeouts and other problems.
CLDAP-Ping uses ASN.1 + UDP (CLDAP) and custom-DCE encoding including DName compressions without
field separation. Finally after finding the sitename we now need to do a DNS SRV lookups to find
the correct IPs to our closest site and fill up the remaining IPs from the global list.
Reviewed-by: Paulo Alcantara (Red Hat) <pc@manguebit.com>
Reviewed-by: Jacob Shivers <jshivers@redhat.com>
Signed-off-by: David Voit <david.voit@gmail.com>
Diffstat (limited to 'mount.cifs.c')
-rw-r--r-- | mount.cifs.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/mount.cifs.c b/mount.cifs.c index 2278995..3b7a6b3 100644 --- a/mount.cifs.c +++ b/mount.cifs.c @@ -1889,8 +1889,11 @@ assemble_mountinfo(struct parsed_mount_info *parsed_info, if (rc) goto assemble_exit; - if (parsed_info->addrlist[0] == '\0') + if (parsed_info->addrlist[0] == '\0') { rc = resolve_host(parsed_info->host, parsed_info->addrlist); + if (rc == 0 && parsed_info->verboseflag) + fprintf(stderr, "Host \"%s\" resolved to the following IP addresses: %s\n", parsed_info->host, parsed_info->addrlist); + } switch (rc) { case EX_USAGE: |