canimus
10/7/2015 - 5:16 PM

influx-queries.sh

curl -G http://localhost:8086/query --data-urlencode "q=CREATE DATABASE racwa"

curl -i -XPOST 'http://localhost:8086/write?db=racwa' --data-binary @influx.line

curl -G 'http://localhost:8086/query?pretty=true' --data-urlencode "db=racwa" --data-urlencode "q=SELECT value FROM cache_on WHERE name='/'"

cat test.tsv | awk -F"\t" '{print "cache_on,client=racwa,region=ap-southwest-2 response="$1",latency="$2",status="$4",name=\""$5"\",code="$6",msg=\""$7"\",user=\""$8"\",bytes="$10",group="$11",active="$12",host=\""$13"\" "$3"000000"}' > influx.line