![]() When flushing DNS cache with that command you will need to enter the admin password. You can verify your hosts modifications immediately with ping, Safari, or any other network app.Ĭhanges take effect immediately though some adjustments may need to be accompanied by a DNS flush which can be done with the following command in macOS 10.12+ through OS X 10.9:ĭscacheutil -flushcache sudo killall -HUP mDNSResponder When finished, hit Control+O followed by ENTER/RETURN to save changes to /private/etc/hosts, then hit Control+X to exit out of nano.Once the hosts file is loaded within nano, use the arrow keys to navigate to the bottom of the hosts file to make your modifications.Enter the administrator password when requested, you will not see it typed on screen as usual with the command line.Type the following command at the prompt:.Launch Terminal, found in /Applications/Utilities/ or launched through Spotlight.Let’s get started making some edits to /etc/hosts in macOS and Mac OS X! Don’t let the command line or Terminal sound intimidating though because it’s not, we’ll make the entire process of editing a Mac hosts file super easy. ![]() ![]() We’ll walk through how to manually edit the hosts file in macOS Big Sur, MacOS Mojave, MacOS Catalina, MacOS High Sierra, MacOS Sierra, OS X El Capitan, Yosemite, OS X Lion, OS X Mountain Lion, and OS X Mavericks, this will be done with the command line using the simple text editor called nano.
0 Comments
Leave a Reply. |