I have an interesting network problem. I have a samba service on hawk. I have an alias for it in DNS:
root@hawk:~# host samba samba.localdomain is an alias for hawk.localdomain. hawk.localdomain has address 192.168.100.6 root@hawk:~# host hawk hawk.localdomain has address 192.168.100.6 root@hawk:~# I can ping by IP address just fine: root@hawk:~# ping 192.168.100.6 PING 192.168.100.6 (192.168.100.6) 56(84) bytes of data. 64 bytes from 192.168.100.6: icmp_seq=1 ttl=64 time=0.083 ms 64 bytes from 192.168.100.6: icmp_seq=2 ttl=64 time=0.034 ms 64 bytes from 192.168.100.6: icmp_seq=3 ttl=64 time=0.044 ms 64 bytes from 192.168.100.6: icmp_seq=4 ttl=64 time=0.052 ms 64 bytes from 192.168.100.6: icmp_seq=5 ttl=64 time=0.063 ms --- 192.168.100.6 ping statistics --- 5 packets transmitted, 5 received, 0% packet loss, time 4101ms rtt min/avg/max/mdev = 0.034/0.055/0.083/0.016 ms root@hawk:~# However, when I try to ping samba by host name: root@hawk:~# ping samba PING samba (192.168.122.1) 56(84) bytes of data. From apt-proxy (192.168.100.12): icmp_seq=2 Redirect Host(New nexthop: hawk.localdomain (192.168.100.6)) From apt-proxy (192.168.100.12): icmp_seq=3 Redirect Host(New nexthop: hawk.localdomain (192.168.100.6)) From apt-proxy (192.168.100.12): icmp_seq=4 Redirect Host(New nexthop: hawk.localdomain (192.168.100.6)) From apt-proxy (192.168.100.12): icmp_seq=5 Redirect Host(New nexthop: hawk.localdomain (192.168.100.6)) --- samba ping statistics --- 5 packets transmitted, 0 received, 100% packet loss, time 4019ms root@hawk:~# host apt-proxy apt-proxy.localdomain is an alias for issola.localdomain. issola.localdomain has address 192.168.100.12 root@hawk:~# 192.168.100.12 is my router. apt-roxy is defined in /etc/hosts: root@hawk:~# cat /etc/hosts 127.0.0.1 localhost 127.0.1.1 hawk.localdomain hawk # The following lines are desirable for IPv6 capable hosts ::1 localhost ip6-localhost ip6-loopback ff02::1 ip6-allnodes ff02::2 ip6-allrouters # For the benefit of virtual machines. 192.168.100.12 apt-proxy 192.168.122.1 samba samba.localdomain root@hawk:~# There is an apt-cacher-ng running on issola, 192.168.100.12. That apt-proxy entry is for the benefit of virtual machines on hawk. This mis-routing prevents the samba clients on hawk from mounting if I use the host name. Other machines have no problems with the share. However, as soon as I change hawk's fstab entry to the loopback address, samba on hawk is fine. Using the IP address works, but I'd rather use an alias in case some time in the future I move the samba service to another machine; all I need do is change the alias. -- Does anybody read signatures any more? https://charlescurley.com https://charlescurley.com/blog/