Optimization of Hongqi LinuxDNS-Linux Enterprise Application-Linux server application information. The following is a detailed description. As one of the basic Internet services, the DNS (Domain Name Server) service plays an extremely important role in the normal operation of the entire Internet. the stability and efficiency of the DNS Service will directly affect the efficiency of users' use of the network. BIND (Berkeley Internet Name Domain) is currently the most widely used Domain Name Server software, in this field in the dominant position. To improve the performance of BIND, an important method is to optimize and configure BIND and its dependent operating systems, libraries, and other software.
In red-flag Linux DC Server5.0, there are many effective DNS optimization methods. The following describes only four methods that greatly improve the DNS performance. QPS (query per second) is used as the criteria for evaluating DNS service performance. To quantify the performance improvement.
Method 1: Change the compilation option. The default compilation option of BIND is "-O2". After "-O3", the performance improvement is shown in table 1 below.
Table 1: Test result comparison table
Compile the parameter O2 O3
QPS 6648 7113
Performance improvement by 4%
Method 2: ICC compiler. Due to the good cooperation between Intel and Hongqi on the ICC compiler project, according to our tests, compilation of Application Software, the use of the ICC compiler is not inferior to the GCC compiler. In the most optimistic case, the performance will be improved by more than 20%. Table 2 below shows the test results for compiling BIND with the ICC compiler, compiler version: Intel ICC-9.0. If you think you are in trouble, you can ask for the compiled Binary Package from Hongqi technical support.
Table 2: ICC compilation result comparison table
Compiler GCC-3.4.3 ICC-9.0
QPS 6648 7758
Performance improvement by 16.7%
Method 3: ICC core. The relationship between Intel ICC and the red flag is described in method 2 above. Therefore, the red-flag Linux DC Server5.0 is the only Linux release with the ICC core. After the DC Server5.0 is fully installed, the gurb option contains the guidance item of the icc core.
After testing and using the ICC core to run the DNS service, the performance has also been slightly improved. Table 3 is shown below.
Table 3: ICC Core Test Results
Compile parameter Kernel-2.6.9-11.19AX Kernel-2.6.9-11.19AX_Icc
QPS 6648 6781
Performance improvement by 2%
Method 4: adjust the number of DNS Service threads. Currently, the bind version basically supports multithreading (after named is started, run the command ps? ELF | grep named), but the default number of threads is not necessarily the best. Therefore, it is necessary to adjust the number of threads of the Service to maximize the current hardware performance.
In the/etc/rc. d/init. d/named Service Startup File, add a line of OPTIONS = "-n NUM" in front. NUM indicates the number of specified processes. Start the service and run the preceding command to check whether the number of threads is set. Then, run the test tool queryperf (in the BIND-VERSION/contrib/queryperf/directory of the BIND source package) to test the maximum QPS of your DNS server. The test results for different hardware vary. Generally, the increase is relatively large. Therefore, you need to patiently test the number of DNS threads.
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