Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

How to return the original log retention after purge kafka topics

Highlighted

How to return the original log retention after purge kafka topics

we have hadoop cluster version 2.6.0.x with 3 kafka machines version - 0.10.0.2.6

we want to purge all data files from all kafka's topics ( purge completely all data )

the CLI for this action should be

kafka-topics.sh --zookeeper localhost:13003 --alter --topic Topic1 --config retention.ms=1000
kafka-topics.sh --zookeeper localhost:13003 --alter --topic Topic2 --config retention.ms=1000
kafka-topics.sh --zookeeper localhost:13003 --alter --topic Topic3 --config retention.ms=1000
kafka-topics.sh --zookeeper localhost:13003 --alter --topic Topic4 --config retention.ms=1000

since we Temporarily update the retention time on the topic to one second (1000 ms )

then how to return the previous original retention!

Note - log.retention.hours = 168 ( from the ambari GUI ) and this is the original value

so how to return the original value (168 hours) back on all topics ? after purge all Topics?

74429-capture.png

Michael-Bronson
Don't have an account?
Coming from Hortonworks? Activate your account here