Hi everyone,
I'm having a problem with Apache Kafka, related with the configuration of the output format. The arquitecture I created is with docker containers, where Apache Kafka is one and the windows host (virtualized in an debian with qemu) with winlogbeat another container.
My configuration file of winlogbeat is correct when I executed:
.\winlogbeat.exe test config
and when windows host established test connection also is OK.
.\winlogbeat.exe test output
When I started winlogbeat, I see in the Apache Kafka Logs the creation of the topic I refer in
winlogbeat.yml
, but the messages with logs are never sent. I am in a rabbit hole with this.
Also I tried to send messages from a python producer with my host and it works.
Pls help, I provide the configuration and the docker-compose.yml
winlogbeat.yml
winlogbeat.event_logs:
- name: Application
ignore_older: 72h
- name: Security
- name: System
- name: Microsoft-Windows-Windows Defender/Operational
output.kafka:
hosts: ["192.168.1.47:9094"]
topic: test
partition.round_robin:
reachable_only: false
required_acks: 1
compression: gzip
max_message_bytes: 1000000
close_inactive: 7m
processors:
- add_host_metadata:
netinfo.enabled: true
docker-compose.yml
kafka1:
image: confluentinc/cp-kafka:latest
container_name: kafka1
hostname: kafka1
ports:
- "9092:9092"
environment:
KAFKA_NODE_ID: 1
KAFKA_LISTENER_SECURITY_PROTOCOL_MAP: 'CONTROLLER:PLAINTEXT,PLAINTEXT:PLAINTEXT,PLAINTEXT_HOST:PLAINTEXT'
KAFKA_ADVERTISED_LISTENERS: 'PLAINTEXT://kafka1:29092,PLAINTEXT_HOST://localhost:9092'
KAFKA_PROCESS_ROLES: 'broker,controller'
KAFKA_CONTROLLER_QUORUM_VOTERS: '1@kafka1:29093'
KAFKA_LISTENERS: 'CONTROLLER://kafka1:29093,PLAINTEXT://kafka1:29092,PLAINTEXT_HOST://0.0.0.0:9092'
KAFKA_CONTROLLER_LISTENER_NAMES: 'CONTROLLER'
KAFKA_INTER_BROKER_LISTENER_NAME: 'PLAINTEXT'
KAFKA_JMX_PORT: 9101
KAFKA_JMX_HOSTNAME: 'localhost'
KAFKA_OFFSETS_TOPIC_REPLICATION_FACTOR: 1
# Replace CLUSTER_ID with a unique base64 UUID using "bin/kafka-storage.sh random-uuid"
# See https://docs.confluent.io/kafka/operations-tools/kafka-tools.html#kafka-storage-sh
CLUSTER_ID: 'MkU3OEVBNTcwNTJENDM2Qk'
the documentation I followed for development are:
https://docs.confluent.io/platform/current/kafka/multi-node.html#connecting-to-ak-on-docker
Why Can’t I Connect to Kafka? | Troubleshoot Connectivity --> Related with docker
thanks for all