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 revert topic deletion

SOLVED Go to solution
Highlighted

how to revert topic deletion

just in case we delete the wrong topic as

/usr/hdp/current/kafka-broker/bin/kafka-topics.sh --zookeeper hdpmaster01:2181 --delete --topic gtom.poli.pri.proc


Topic gtom.poli.pri.procis already marked for deletion

and now we want to revert it

what are the steps to revert topic deletion?

all folders topics as the following are still exists under /var/kafka/kafka-logs

gtom.poli.pri.procis-23

gtom.poli.pri.procis-45

gtom.poli.pri.procis-34

.

.

Michael-Bronson
1 ACCEPTED SOLUTION

Accepted Solutions

Re: how to revert topic deletion

Wק can abort the deletion by running the following command in zookeeper:

rmr /admin/delete_topics/gtom.poli.pri.procis 

Note that this will only prevent the deletion to proceed if it has not already started. If anything has already been deleted, it's gone

Michael-Bronson
1 REPLY 1

Re: how to revert topic deletion

Wק can abort the deletion by running the following command in zookeeper:

rmr /admin/delete_topics/gtom.poli.pri.procis 

Note that this will only prevent the deletion to proceed if it has not already started. If anything has already been deleted, it's gone

Michael-Bronson