Monday, June 8, 2015

To find the time response of a website

Using the command 'curl', the time response of a website or a webpage can be found. The following is an example to find the response time for the website 'www.w3.org'

curl -s -w '\nLookup time:\t%{time_namelookup}\nConnect time:\t%{time_connect}\nPreXfer time:\t%{time_pretransfer}\nStartXfer time:\t%{time_starttransfer}\nTotal time:\t%{time_total}\n' -o /dev/null www.w3.org

The response will be:
Lookup time: 0.004
Connect time: 0.062
PreXfer time: 0.062
StartXfer time: 0.123
Total time: 0.248