An MDMP file is a compressed data file created by Windows after a program error or crash. When Kafka crashes, the JVM (Java Virtual Machine) will generate a MDMP file. This file contains data "dumped" from the program's memory space, which includes information about the error that can be used for debugging.
Although this is a helpful file, the MDMP file is very large and uses a lot of space in the installation path.
For example,

To avoid this, you can ask the JVM to generate a "minidump" that will take up less space and still provide you with helpful information.
IF ["%KAFKA_JVM_PERFORMANCE_OPTS%"] EQU [""] (
set KAFKA_JVM_PERFORMANCE_OPTS=-server -XX:+UseG1GC -XX:MaxGCPauseMillis=20 -XX:InitiatingHeapOccupancyPercent=35 -XX:+ExplicitGCInvokesConcurrent -Djava.awt.headless=true
)IF ["%KAFKA_JVM_PERFORMANCE_OPTS%"] EQU [""] (
set KAFKA_JVM_PERFORMANCE_OPTS=-server -XX:+UseG1GC -XX:MaxGCPauseMillis=20 -XX:InitiatingHeapOccupancyPercent=35 -XX:+ExplicitGCInvokesConcurrent -Djava.awt.headless=true -XX:-CreateMinidumpOnCrash
)
This generates a minidump rather than a large MDMP file dump.