I don't think you want to use the JSON input to do the separation. You probably want to use a "Split Group" bucket aggregation to define the groups/buckets that you want "sum of bytes" aggregation to be calculated in.
Since it seems you want to group by an IPv4 address I recommend using the "IPv4 Range" bucket aggregation and then define the address ranges that you want represented on the dst_addr field. If you're comfortable with CIDR masks, you can use those too.
My data is a little different from yours, so I used different ranges, but this is what I did to split the metric by IP range:
Thanks. I don't have my fields configured for the IP type though. Can't remember why I didn't do that. The IP field type does support wildcard searches? Some of my dashboards rely on being able to do something like 192.168.0.*.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.