Thanks for you detailed input .
I have around 16 Topics with varying partitions - I kknow about workers but i assume i have difficulty in pushing the large batches to kafka -
You are right i have to start with base numbers but some how i had to push large number of events to kafka ( i have 66 brokers ) and i have 15 topics with 5 parition and 2 replica and 1 topic with 40 partition and 2 replica
I started a new instance of filebeat on same server - Now i have 2 instance of filebeat running where 1 instance of filebeat has all other topics (15 topics ) and other instance has only one log file which has huge load .
The configuration for the second instance is around -
> - type: log
>
> enabled: true
>
> close_inactive: 3h
> scan_frequency: 100ms
> paths:
> - /var/log/file.log
>
> fields:
> log_topic: 109154002
>
> max_procs: 30
> queue.mem:
> events: 2000000
> flush.min_events: 2000000
> flush.timeout: 50ms
> http.enabled: false
> output.kafka:
> # initial brokers for reading cluster metadata
> hosts: ["kafkabrokers"]
>
> # message topic selection + partitioning
> topic: '%{[fields.log_topic]}'
> partition.round_robin:
> reachable_only: true
>
> required_acks: 1
> worker: 40
> # compression: gzip
> bulk_max_size: 2000000
> max_message_bytes: 1000000
**But after new instance i amble to see improved performance **
**> The logs for new Instance which send logs for one instance is as follows **
>
2019-03-14T12:43:13.778+0530 INFO [monitoring] log/log.go:144 Non-zero metrics in the last 30s {"monitoring": {"metrics": {"beat":{"cpu":{"system":{"ticks":65828510,"time":{"ms":10652}},"total":{"ticks":656865230,"time":{"ms":99155},"value":656865230},"user":{"ticks":591036720,"time":{"ms":88503}}},"handles":{"limit":{"hard":4096,"soft":1024},"open":46},"info":{"ephemeral_id":"48423bad-0ff9-4929-a316-3580953aa28f","uptime":{"ms":89100064}},"memstats":{"gc_next":1305428208,"memory_alloc":663167712,"memory_total":345657458030664,"rss":71311360}},"filebeat":{"events":{"active":1126,"added":62352,"done":61226},"harvester":{"open_files":4,"running":4}},"libbeat":{"config":{"module":{"running":0}},"output":{"events":{"acked":61226,"batches":49,"total":61226}},"outputs":{"kafka":{"bytes_read":2872816,"bytes_write":54173422}},"pipeline":{"clients":1,"events":{"active":995,"published":62221,"total":62221},"queue":{"acked":61226}}},"registrar":{"states":{"current":4,"update":61226},"writes":{"success":49,"total":49}},"system":{"load":{"1":22.27,"15":18.72,"5":19.47,"norm":{"1":0.5568,"15":0.468,"5":0.4868}}}}}}
2019-03-14T12:43:43.782+0530 INFO [monitoring] log/log.go:144 Non-zero metrics in the last 30s {"monitoring": {"metrics": {"beat":{"cpu":{"system":{"ticks":65839950,"time":{"ms":11439}},"total":{"ticks":656966610,"time":{"ms":101373},"value":656966610},"user":{"ticks":591126660,"time":{"ms":89934}}},"handles":{"limit":{"hard":4096,"soft":1024},"open":46},"info":{"ephemeral_id":"48423bad-0ff9-4929-a316-3580953aa28f","uptime":{"ms":89130064}},"memstats":{"gc_next":985132336,"memory_alloc":515555904,"memory_total":345713813718576,"rss":-235307008}},"filebeat":{"events":{"active":-588,"added":64101,"done":64689},"harvester":{"open_files":4,"running":4}},"libbeat":{"config":{"module":{"running":0}},"output":{"events":{"acked":64689,"batches":50,"total":64689}},"outputs":{"kafka":{"bytes_read":2990569,"bytes_write":56883450}},"pipeline":{"clients":1,"events":{"active":54,"published":63748,"total":63748},"queue":{"acked":64689}}},"registrar":{"states":{"current":4,"update":64689},"writes":{"success":50,"total":50}},"system":{"load":{"1":23.84,"15":18.93,"5":20.06,"norm":{"1":0.596,"15":0.4733,"5":0.5015}}}}}}
Logs for the other instance which sends logs for all other 15 topics is as follows
2019-03-14T12:44:06.790+0530 INFO [monitoring] log/log.go:144 Non-zero metrics in the last 30s {"monitoring": {"metrics": {"beat":{"cpu":{"system":{"ticks":7816360,"time":{"ms":2864}},"total":{"ticks":88429430,"time":{"ms":38575},"value":88429430},"user":{"ticks":80613070,"time":{"ms":35711}}},"handles":{"limit":{"hard":4096,"soft":1024},"open":130},"info":{"ephemeral_id":"6ec4cdc3-ae72-470a-a5d9-b60f019aae4d","uptime":{"ms":88800044}},"memstats":{"gc_next":280959328,"memory_alloc":216458960,"memory_total":54420119051912}},"filebeat":{"events":{"active":220,"added":68641,"done":68421},"harvester":{"open_files":64,"running":64}},"libbeat":{"config":{"module":{"running":0}},"output":{"events":{"acked":67820,"active":424,"batches":261,"total":68244}},"outputs":{"kafka":{"bytes_read":606389,"bytes_write":20841371}},"pipeline":{"clients":20,"events":{"active":445,"filtered":177,"published":68264,"total":68442},"queue":{"acked":67820}}},"registrar":{"states":{"current":67,"update":68421},"writes":{"success":263,"total":263}},"system":{"load":{"1":27.56,"15":19.32,"5":21.16,"norm":{"1":0.689,"15":0.483,"5":0.529}}}}}}
2019-03-14T12:44:06.833+0530 INFO kafka/log.go:53 client/metadata fetching metadata for all topics from
2019-03-14T12:44:36.771+0530 INFO [monitoring] log/log.go:144 Non-zero metrics in the last 30s {"monitoring": {"metrics": {"beat":{"cpu":{"system":{"ticks":7819090,"time":{"ms":2739}},"total":{"ticks":88467390,"time":{"ms":37975},"value":88467390},"user":{"ticks":80648300,"time":{"ms":35236}}},"handles":{"limit":{"hard":4096,"soft":1024},"open":130},"info":{"ephemeral_id":"6ec4cdc3-ae72-470a-a5d9-b60f019aae4d","uptime":{"ms":88830040}},"memstats":{"gc_next":247090800,"memory_alloc":200991592,"memory_total":54442067279696,"rss":-3309568}},"filebeat":{"events":{"active":-186,"added":68267,"done":68453},"harvester":{"open_files":64,"running":64}},"libbeat":{"config":{"module":{"running":0}},"output":{"events":{"acked":68692,"active":-424,"batches":256,"total":68268}},"outputs":{"kafka":{"bytes_read":589044,"bytes_write":20467182}},"pipeline":{"clients":20,"events":{"active":34,"filtered":185,"published":68282,"total":68466},"queue":{"acked":68692}}},"registrar":{"states":{"current":67,"update":68453},"writes":{"success":258,"total":258}},"system":{"load":{"1":20.05,"15":18.95,"5":19.9,"norm":{"1":0.5013,"15":0.4738,"5":0.4975}}}}}}