log4j:ERROR Could not read configuration file from URL

Hello everyone,

I’m trying to run a kafka connect cluster in distributed mode on Windows.

When I try to lunch the command C:\Users\dinardo\Desktop\Confluent\confluent-7.3.0\bin\windows>connect-distributed.bat C:\Users\dinardo\Desktop\Confluent\confluent-7.3.0\etc\kafka\connect-distributed.properties

gives me an error:
log4j:ERROR Could not read configuration file from URL [file:C:/Users/dinardo/Desktop/Confluent/confluent-7.3.0/config/connect-log4j.properties -Dlog4j.config.dir=C:/Users/dinardo/Desktop/Confluent/confluent-7.3.0/config].

java.io.FileNotFoundException: C:\Users\dinardo\Desktop\Confluent\confluent-7.3.0\config\connect-log4j.properties -Dlog4j.config.dir=C:\Users\dinardo\Desktop\Confluent\confluent-7.3.0\config.

I thought the problem was that config directory doesn’t exist in the path so I’ve created it with connect-log4j.properties file inside but the issue is still the same.

Can anyone help me? thank you

hey @SeverusP

Windows is basically not a supported for running Kafka environments.
I would rather recommend to run Kafka inside Docker or with WSL.

What may help solving your issue:

  • the file exists I assume
  • try to run the cmd with “run as Admin”

again I would recommend to use Docker or Linux or WSL.

Best,
Michael

2 Likes

The error is including the -Dlog4j.config.dir system property, which it shouldn’t, but as mentioned, the BATCH scripts haven’t been modified in a long time to fix any problems with them, whereas the unix scripts are used daily by anyone running these services.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.