defaults write /System/Library/LaunchDaemons/com.apple.mDNSResponder ProgramArguments -array “/usr/sbin/mDNSResponder” “-launchd” “-NoMulticastAdvertisements”
To undo this, you would run:
defaults write /System/Library/LaunchDaemons/com.apple.mDNSResponder ProgramArguments -array “/usr/sbin/mDNSResponder” “-launchd”
If you have other elements in the array you could also use the following to simply append to the end of it:
defaults write /System/Library/LaunchDaemons/com.apple.mDNSResponder ProgramArguments -array-add “-NoMulticastAdvertisements”
When I got home from MacSysAdmin, I had a request to disable Multicast DNS in Debian, which was done by editing the Avahi daemon. The file was avahi-daemon (aptly named) located in the /etc/default directory. The settting to change in there is AVAHI_DAEMON_START which needs to be set to 0.