目錄

名詞介紹-Domain Name Service (DNS)

DNS提供將Domain name進行解析成IP的服務,需使用53/TCP、53/UDP(通常為UDP)進行連線。

https://amingosec.blog/wp-content/uploads/2020/01/img_4661.jpg?w=744

DNS查詢

在電腦在需要連線Domain時,會優先查找主機內的hosts file,並利用該資料進行連線。如果沒有找到,將再對所設定的DNS提出Domain查詢的請求。

Linux 先找/etc/hosts
windows 先找 C:\windows\System32\drivers\etc\hosts
依RFC 3330 localhost 會指到127.0.0.1

DNS設定(Linux)

http://www.geekpills.com/operating-system/linux/configure-master-slave-bind-dns-in-linux

延伸閱讀

參考資料

https://tools.ietf.org/html/rfc3330

https://www.cloudflare.com/learning/dns/what-is-dns/

https://support.microsoft.com/zh-tw/topic/microsoft-tcp-ip-%E4%B8%BB%E6%A9%9F%E5%90%8D%E7%A8%B1%E8%A7%A3%E6%9E%90%E9%A0%86%E5%BA%8F-dae00cc9-7e9c-c0cc-8360-477b99cb978a