When trying to access a samba share with smblcient -L //localhost from my local Samba Server, I get after a delay the error message protocol negotiation failed: NT_STATUS_IO_TIMEOUTWhat are the debugging steps to get to the root of this problem systematically?Background:For my own training purposes I am setting up a simple shared folder over a samba server on a CentOS 7 virtual machine.I added following lines to the smb.conf file and created the directory, selinux configuration and firewall rule.[sambashare]comment = sambasharepath = /sambasharepublic = yeswritable = yeswrite list = +users
How to debug NT_STATUS_IO_TIMEOUT?
centos;virtualbox;samba
Solution: You haven't configured DNS name resolution for your servername and have to set the servername either in the /etc/hosts manually or in your DNS server.Debug process:In the case of NT_STATUS_IO_TIMEOUT try to use a network traffic analyser like tcpdump. (ex. tcpdump -i >network interface<)If following lines appear:07:57:54.726390 IP 10.0.2.9.39939 > 10.0.2.1.domain: 20986+ A? server.example.local. (38)07:57:54.726648 IP 10.0.2.9.39939 > 10.0.2.1.domain: 44015+ AAAA? server.example.local. (38)07:57:54.727069 IP 10.0.2.9.48743 > 10.0.2.1.domain: 34381+ PTR? 1.2.0.10.in-addr.arpa. (39)07:57:54.732388 IP 10.0.2.1.domain > 10.0.2.9.39939: 20986 NXDomain* 0/0/0 (38)07:57:54.733400 IP 10.0.2.1.domain > 10.0.2.9.48743: 34381 NXDomain* 0/0/0 (39)07:57:54.733642 IP 10.0.2.9.53191 > 10.0.2.1.domain: 24458+ PTR? 9.2.0.10.in-addr.arpa. (39)This means that the smbclient isn't able to resolve the servername server.example.local which is a DNS resolution problem.