curl 超時問題解決


curl -o /dev/null -s -w %{time_namelookup}---%{time_connect}---%{time_starttransfer}---%{time_total}---%{speed_download}"\n" https://www.baidu.com
  • -o:把curl 返回的html、js 寫到垃圾回收站[ /dev/null]
  • -s:去掉所有狀態
  • -w:按照后面的格式寫出rt
  • time_namelookup:DNS 解析域名時間
  • time_commect:client和server端建立TCP 連接的時間
  • time_starttransfer:從client發出請求;到web的server 響應第一個字節的時間
  • time_total:client發出請求;到web的server發送會所有的相應數據的時間
  • speed_download:下周速度 單位 byte/s


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM