sudo sh -c 'cat <<EOF > /etc/aws-kinesis/agent.json
{
"cloudwatch.endpoint": "monitoring.<AWSRegion>.amazonaws.com",
"cloudwatch.emitMetrics": true,
"firehose.endpoint": "firehose.us-east-1.amazonaws.com",
"flows": [
{
"filePattern": "/var/log/httpd/access_log",
"deliveryStream": "qls-5241374-18099f18c163cfb7-deliveryStream-mX6phCRMYB8w"
}
]
}
EOF'
SELECT clientip,
COUNT(*) clientip
FROM "logsdatabase"."logs"
GROUP BY clientip;
SELECT
clientip, COUNT(DISTINCT agent) as num_agents
FROM "logsdatabase"."logs"
GROUP BY clientip, agent;