Avahi
From wikinotes
Avahi is a linux mdns implementation.
It allows you to resolve hostnames to ip addresses over your local network.
Documentation
arch wiki https://wiki.archlinux.org/index.php/Avahi wikipedia https://en.wikipedia.org/wiki/Avahi_(software)
Locations
/etc/nsswitch.conf
Install
sudo pacman -S avahi sudo pacman -S nss-mdns sudo systemctl enable avahi-daemon.service # CLIENT && HOST: allow in proto UDP dport 5353 # HOST: allow in proto ICMPV6
Configuration
{hostname}.local resolution
On both the host/client
# /etc/nsswitch.conf # add 'mdns_minimal [NOTFOUND=return]' before 'resolve' and 'dns' hosts: files mymachines myhostname mdns_minimal [NOTFOUND=return] resolve [!UNAVAIL=return] dnsYou'll also need to configure your firewall so
- (host/client) UDP/5353 in is accepted
- (client) ICMPV6 in is accepted
# /etc/nftables.conf # (nftables example) table inet filter { chain input { # ... ip protocol icmp accept; ip6 nexthdr icmpv6 accept; } }