Hi ! Is this command also delete the ledger on Boo...
# general
m
Hi ! Is this command also delete the ledger on Bookkeeper side ?
Copy code
pulsar-managed-ledger-admin delete-managed-ledger-ids
y
this command will not delete ledger from bookie directly. but once the meta data deleted, bookie will clean up the ledger when bookie garbage collection (compaction) kick in.
m
Thanks, How the BK GC will know that a ledger disappear from the managed ledger ?
managed ledger is just another ledger. the treatment of gc is the same.
m
OK thank you
from your last link, the diagram show a broker deleting both the ledger reference in the managed ledger and the ledger in Bookkeeper side But, the command
Copy code
delete-managed-ledger-ids
seems to only delete on managed-ledger side, (https://github.com/apache/pulsar/blob/master/bin/pulsar-managed-ledger-admin#L114) So the ledgers can still exists from BK point of view ?
y
managed ledger is about subscription/cursor position…. if you delete managed ledger, it is like you remove subscription. This means the retention, backup mechanism kicks in and old ledgers will be marked as deleteable.