Skip to content

Instantly share code, notes, and snippets.

@missinglink
Created December 17, 2014 10:37
Show Gist options
  • Select an option

  • Save missinglink/4ef23b4edd232c7cbbb8 to your computer and use it in GitHub Desktop.

Select an option

Save missinglink/4ef23b4edd232c7cbbb8 to your computer and use it in GitHub Desktop.
Measuring response times for a curl request
#!/bin/bash
echo "\n
time_namelookup: %{time_namelookup}\n
time_connect: %{time_connect}\n
time_appconnect: %{time_appconnect}\n
time_pretransfer: %{time_pretransfer}\n
time_redirect: %{time_redirect}\n
time_starttransfer: %{time_starttransfer}\n
----------\n
time_total: %{time_total}\n
\n" >> curl-format.txt;
curl -w "@curl-format.txt" -o /dev/null -s http://myurl
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment