Ubuntu DNS information modification found that recently opened various web pages, often play the same advertisement for me, It should be DNS hijacking. Modify it ~ Java code sudo vim/etc/resolv. conf will find that the file starts with Java code # Dynamic resolv. conf (5) file for glibc resolver (3) generated by resolvconf (8) # do not edit this file by hand -- your changes will be overwritten. this file is dynamically generated BY the resolvconf program. do not modify it manually. The modified information will be overwritten. Solution: Java code cd/etc/resolvconf/resolv. conf. d touch tail vim tail then follow resolv. add the internationally recognized DNS Server Java code in the conf DNS format # nameserver 8.8.8.8 nameserver 8.8.4.4 provided by Google # nameserver 208.67.222.222 provided by OpenDNS, restart it, and view resolv. conf, you will find that the modified Java code/etc/init. d/resolvconf restart sudo vim/etc/resolv. conf