Install pdnsd in magiclinux to accelerate domain name resolution-Linux Enterprise Application-Linux server application information. The following is a detailed description. Today, magiclinux 2.1 beta1 was installed. When I browsed the web page using firefox, I always felt that the speed was not satisfactory. After firefox was optimized, it was not significantly improved. Then observe the status bar and find that dns resolution takes a long time in firefox. In windows, dns cache is provided, but not in magiclinux (pdnsd is used as dns cache by default in Everset linux ), so I decided to add a dns cache to my ML.
So I decided to install a pdnsd for my ML and download the pdnsd.
Installation:
Rpmbuild -- rebuild pdnsd-1.2.6-par.src.rpm
Rpm-ivh/usr/src/mBuild/RPMS/i686/pdnsd-1.2.6-par.i686.rpm
Configuration:
Cp/etc/pdnsd. conf. sample/etc/pdnsd. conf
Change/etc/pdnsd. conf: In the server segment, change the ip value to the address of your nameserver; change uptest to query (many ns do not respond to ping)
Add 127.0.0.1 to the beginning of/etc/resolv. conf
Start
Nohup/usr/sbin/pdnsd &
Set auto-start with System
Echo/usr/sbin/pdnsd &>/etc/rc. local
Test results:
CODE: dig hew.linuxsky.org . . . . ; Query time: 156 msec ; SERVER: 218.108.248.245 #53 (218.108.248.245) ; WHEN: Sat Feb 9 21:34:34 2008 ; Msg size rcvd: 78
Dig hew.linuxsky.org . . . . ; Query time: 6 msec ; SERVER: 218.108.248.245 #53 (218.108.248.245) ; WHEN: Sat Feb 9 21:34:34 2008 ; Msg size rcvd: 78 ========================================================== ============ Dig blog.linuxsky.org . . . ; Query time: 102 msec ; SERVER: 127.0.0.1 #53 (127.0.0.1) ; WHEN: Sat Feb 9 21:31:24 2008 ; Msg size rcvd: 93
Dig blog.linuxsky.org . . . ; Query time: 2 msec ; SERVER: 127.0.0.1 #53 (127.0.0.1) ; WHEN: Sat Feb 9 21:31:24 2008 ; Msg size rcvd: 93 |