DZone Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world

Jeffrey has posted 20 posts at DZone. View Full User Profile

Edit The Hosts File In Mac OS X

  • submit to reddit
        The hosts file is a text document that maps IP addresses to hostnames. It's similar to, but trumps, DNS. To edit the hosts file in Mac OS X, launch Terminal and type:

sudo vi /etc/hosts