课程: Linux System Engineer: Networking and SSH
今天就学习课程吧!
今天就开通帐号,24,700 门业界名师课程任您挑!
Change DNS server
- [Instructor] There is no live configuration for DNS servers. Our only choice is to change configuration files. The global DNS servers are stored in /etc/resolv.conf. Interface specific DNS servers are stored in the interface specific network configuration files in /etc/sysconfig/network-scripts. We'll discuss interface specific DNS settings in the next chapter, when we discuss manual network configurations. To add or change a global DNS server, just edit the /etc/resolv.conf file and add a line specifying the DNS server. For instance, to add Google's free DNS server we could type sudo, space, vi, space, slash, etc, slash, resolv.conf. and hit enter. We're going to answer mode by pressing i and then we'll go down to the last line, and we'll add nameserver, space, 8.8.8.8 and then well save it, by doing escape colon x, and hitting enter. And that's it. Linux queries name servers in order, so if you want the new DNS server queried first, just put it at the top. There's also no need to…
随堂练习,边学边练
下载课堂讲义。学练结合,紧跟进度,轻松巩固知识。