Jared Heinrichs

  • Technology Blog
  • Winnipeg Computer Repair
  • Winnipeg Photographer
  • Cooking With Jared
You are here: Home / Operating System / Mac OS X / Mac OS X: How to look up ".local" hostnames

Oct 25, 2010 By Jared Heinrichs Leave a Comment

Mac OS X: How to look up ".local" hostnames

You have most likely come here because you’re having an issue with your Mac and your computer is on a .local domain. For example:

  • jaredheinrichs.com – This is my external domain
  • jaredheinrichs.local – This could be an internal domain for my home network

Using separate domain names has the advantage of having quicker internal network access.

So why does this matter? Well Apple in their bright wisdom decided to implement a technology call Bonjour. Bonjour ships with iTunes and messes with your systems DNS settings. Bonjour is installed by default on the Mac. It turns out bonjour uses .local for all network communications. I’d say at least 1/2 (I just pulled that out of my butt) of all small businesses use .local as their internal domain name.

Can you see where I am going with this? Below is Apple’s solution to the .local problem and how to kind of work around it.

Summary

The Multicast DNS feature of Bonjour technology allows devices on a local network to connect to each other by name without a separate DNS server. See this article for more details. By default, any hostname ending in .local is treated as a Bonjour host rather than by querying the DNS server entries in Network preferences.

Though the .local domain is not defined as a valid top-level domain on the Internet, some private networks have DNS servers that assign hostnames in the .local domain. By default Mac OS X does not use the DNS server to resolve these names. This may result in unexpected failures to connect to .local hostnames defined by your server. If .local names are assigned by a DNS server on your network, use the solution below to configure Mac OS X 10.3 to look up .local names in both ways.

Products Affected

Mac OS X 10, Bonjour

Create and run the following script. To create the script, execute each of these commands in Terminal (/Applications/Utilities/). Each command is preceded by the dollar sign ($), which represents the Terminal prompt. You must be logged with an administrator account to perform these steps. After the first command (sudo), you will be prompted to enter your administrator password. After typing each command, press Return to execute it. After entering the "cat" command, you will not see a prompt ($) for the next four lines, though you must still press Return after each. For the line that says "[Control-D]", press Control-D.

The commands:

Mac OS X: How to look up ".local" hostnames 01

 

These steps create an executable shell script named "EnableUnicastDotLocal" that will create and populate the necessary configuration files to enable dual lookups of .local hostnames.

To run the script, execute this command:

Mac OS X: How to look up ".local" hostnames 02

Important: The address of the DNS server configured by this script for .local name lookups will not change automatically if your default DNS server address changes. (Your DNS server address may change if you change network locations, if a change is made by your DHCP server administrator, or if you change it manually in Network preferences.) To change the DNS server used for lookups in the .local domain, you must run this script again. To disable unicast DNS lookups entirely after running this script, delete the file /etc/resolver/local.1.

Note: For the Active Directory plug-in to work with .local domains, you must update to Mac OS X 10.3.3 or later.

Filed Under: Mac OS X Tagged With: How To

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Categories

  • Board Game Rules
  • Camera
  • Computer Hardware
    • Blackberry
    • drivers
    • iPad
    • Magic Jack
    • USB
  • Damn Small Linux
  • Exam Notes
  • Facebook
  • FREE Flashcards
  • Games
    • PC
      • League of Legends
    • Wii
    • xbox 360
  • Music
  • Networking
    • Cisco Certification
    • Mitel
    • Palo Alto Firewall
  • News
    • Google
    • Microsoft
  • Operating System
    • Active Directory (2003)
    • Android
    • Command Prompt
    • Damn Small Linux
    • Group Policy
    • Hyper-V
    • IIS
    • ISA 2006
    • Mac OS X
    • Microsoft Exchange Server
    • Powershell
    • Security
    • SME Server
    • Terminal Server 2003
    • Ubuntu Linux
      • Adito Web SSL VPN
      • OpenVpn-als
      • Webmin
    • Virtual Machine Manager
    • Windows 2003 SBS
    • Windows 2003 Server
    • Windows 2008
    • Windows 2008 R2
    • Windows 2012R2
    • Windows 7
    • Windows 8
    • Windows Command Line
    • Windows Deployment Services
    • Windows Server Backup
    • Windows Vista
    • Windows XP
  • Phones
  • Photography
  • Photos
    • Animals
    • Misc
    • Nature
    • Portraits
  • Portfolio
  • Programming
    • CSS
    • HTML
    • jQuery
    • MySQL
    • PHP
    • Script
  • Programs
    • Acrobat
    • Acrobat Reader
    • Adobe Dreamweaver
    • Adobe Illustrator
    • Adobe Photoshop
    • Anti-virus Software
    • Antivirus
    • Backup Exec
    • Bittorent
    • Blackberry BESADMIN
    • Internet Explorer 9
    • Lightroom
    • Microsoft Office
    • Netbeans
    • Onenote
    • Outlook
    • Shelby
    • Sysprep
    • Trend
    • Video Editing
    • Visual Studio
    • Windows Live Writer
    • WireShark
    • XP Mode
    • Zarafa
  • Recipe
  • Review
  • Software Links
  • Troubleshooting
  • Uncategorized
  • Videos
  • Web Applications
    • Brage
    • Google
    • Spiceworks
    • Wordpress
  • Web Browsers
    • Internet Explorer
  • Web Server
    • XAMPP
  • Winnipeg
    • ISP

Try searching this site!

Copyright © 2021 Winnipeg Web Design