Nginx http2.0 performance is too counter-clockwise, HTTPS website performance optimization

Source: Internet
Author: User
Tags file size http 2 website performance

m## about http2.0
Please read: [HTTP 2.0] [http://mrpeak.cn/blog/http2/] background

Our seven-layer load layer, using 5 24u+64g memory of the physical machine branch nginx do HTTPS plus decryption and proxy_pass. The daily commute time, 5 machine CPU basically in about 50%, be counted type.
Optimization means: keepalive, change TLS1.2 encryption algorithm optimization (reference:), etc., the effect is not small.
Especially concise keepalive options, regardless of how the server support, the key is that the client is not with you keep, you play a fart. test Process hardware: 24u+64g Physical Machine 2 units, 1 sets with the test, 1 runs NGX, the same LAN, 1GB network card.

Nginx-v:

version:openresty/1.9.7.3
Built by GCC 4.8.5 20150623 (Red Hat 4.8.5-4) (GCC)
Built with OpenSSL 1.0.1e-fips 2013
TLS SNI Support Enabled
–with-http_v2_module

Apache's AB pressure measuring tool: Yum install boom is a Golang implementation of the analog AB pressure measuring tool: https://github.com/rakyll/boom NGHTTP2 h2load pressure measurement tool: https://github.com /TATSUHIRO-T/NGHTTP2 CentOS-7 64-bit test file size: 5k,10k pictures, HTTPS test for static files. The test process is simple to see parameters:-c=100~3000,-n=1k~10kw of various combinations, the use of h2load when-m=1~1000 have tried,-m range size, the HTTP2 results are not too large. Figure:

Discharge diagram you will understand:

The following figure is used when using AB with boom:

At this point AB and boom both have the use of-K, anyway how to play, measurement and time are probably at this level.
For example, the following command basically runs for half an hour:

Boom-c 1000-n 1000000-allow-insecure https://172.16.9.234/5k.jpg
Ab-c 1000-n 1000000-khttps://172.16.9.234/5k.jpg

When the parameter is changed to HTTP2:

H2load-c 1000-n 1000000-m1 https://172.16.9.234/5k.jpg

H2load operation results are as follows:

Again the following figure is H2load test HTTP2:

Gigabit network card, outgoing traffic is full. Conclusion

The following conclusions after repeated testing, only on behalf of my opinion, reproduced please specify From:toontong. Equivalent concurrent numbers, http2.0 only 43 seconds to transmit the 4.3G data, and http1.1 for more than 40 minutes. Single-talk transmission performance increased 10 times times more than, to our key HTTPS CPU occupancy effect is very obvious. Of course, the overall performance of the Web service is not 10 times times, because the connection is based on the need, and more reasons to deep research HTTP2 principle. go1.6 after the Http2-client library support, low version go feel can use HTTPS://GITHUB.COM/TATSUHIRO-T/GO-NGHTTP2 If the true popularity of http2.0, the entire interconnection of traffic, the Internet company's machine savings, are the great gospel.

Contact Us

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

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.