Wasn't able to find much info on configuring mDNSResponder. Most posts talk about using Avahi or Netatalk. I was using Avahi on FreeBSD 11 and recently clean installed FreeBSD 12-Release and read somewhere that mDNSResponder is more lightweight (but don't quote me on that ).
Anyhow, I was able to get it working with the following steps so figured I'd share in case it helps anyone else, too (thanks to the info I found in https://forums.freebsd.org/threads/mdnsresponder-not-running.46659/).
1. Install net/mDNSResponder with pkg:
2. Create an mdnsresponder.conf file:
For example, to broadcast services for SSH (port 22) and Samba (port 445):
3. Add the following to /etc/rc.conf:
4. Start the service:
From a Mac on the network you can then use
If you make any edits to the mdnsresponder.conf file you can restart it to apply the changes:
Anyhow, I was able to get it working with the following steps so figured I'd share in case it helps anyone else, too (thanks to the info I found in https://forums.freebsd.org/threads/mdnsresponder-not-running.46659/).
1. Install net/mDNSResponder with pkg:
sudo pkg install mDNSResponder
2. Create an mdnsresponder.conf file:
sudo pico /usr/local/etc/mdnsresponder.conf
For example, to broadcast services for SSH (port 22) and Samba (port 445):
Code:
Server Name
_ssh._tcp. local.
22
Server Name
_smb._tcp. local.
445
3. Add the following to /etc/rc.conf:
sudo pico /etc/rc.conf
Code:
# mDNSResponder
mdnsresponderposix_enable="YES"
mdnsresponderposix_flags="-f /usr/local/etc/mdnsresponder.conf"
4. Start the service:
sudo service mdnsresponderposix start
From a Mac on the network you can then use
ssh hostname.local
to connect or look for the SMB server in the Finder's sidebar.If you make any edits to the mdnsresponder.conf file you can restart it to apply the changes:
sudo service mdnsresponderposix restart
Last edited: