Use Curl to troubleshoot Web site performance and time-consuming issues

Source: Internet
Author: User

Example: Use Curl to view all time-consuming information:

$ Curl-o/dev/null-s-W%{time_namelookup}::%{time_connect}::%{time_starttransfer}::%{time_total}::%{speed_ Download} "\ n" "http://www.baidu.com"
0.004::0.008::0.015::0.015::162425.000


The Curl parameter is detailed:

-O: Writes Curl output All label information to the garbage collection station/dev/null

-S: Remove all attributes

-W: Outputs the result according to the expression style provided in the following paragraph


Time_namelookup:dns Resolving the time domain name [www.baidu.com]

Time_commect:client and server end time to establish TCP connections

Time_starttransfer: A request from the client; the server in the Web responds to the first byte of time

Time_total:client sends a request to the Web server to send all the corresponding data time

Speed_download: Download Speed byte/s


0.004:dns the time unit of the server parsing www.baidu.com is s

0.008:client the time that a request is made to C/s to establish TCP, including the time of DNS resolution

0.015:client the time at which the first byte of a response is emitted, including the previous 2 time

0.015:client sends a request, to S to send the response data all to the client, and to turn off the connect time

162425.000: Speed of downloading data

1. Establish a TCP connection to the time that the server returns the first byte of the client: 0.015s-0.008s = 0.007s

2. Time the server sends response data to client: 0.015s-0.015s = 0.0s


This article is from the "Reiling ¿âë¹anti" blog, be sure to keep this source http://luweiv998.blog.51cto.com/4659209/1969224

Use Curl to troubleshoot Web site performance and time-consuming issues

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.