The mysterious bogon in the Mac terminal and the mysterious bogon in the Mac Terminal

Source: Internet
Author: User

The mysterious bogon in the Mac terminal and the mysterious bogon in the Mac Terminal

Originally, the terminal displays the computer name. The result is "bogon" in the past two days. It is virtual and hypocritical to look up the word "bogon. Then, if it turns out that the DNS server will first query the direction resolution result of the local ip address. If the query fails, the computer name will be displayed. Because our DNS incorrectly returns the NS query result with the reserved address reversed to bogon, bogon should be used to refer to the fake IP address instead of the reserved IP address. Therefore, the strange name bogon may be printed as a computer name from time to time. So how can I make the terminal show only the computer name we want, instead of always returning results from DNS?

There are two methods:

1. Set DNS to Google's DNS server address 8.8.8.8

2. Configure on the terminal

Sudo hostname your-desired-host-name

Sudo scutil -- set LocalHostName $ (hostname)

Sudo scutil -- set HostName $ (hostname)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.