Github user flier commented on a diff in the pull request:
https://github.com/apache/zookeeper/pull/180#discussion_r102263924
--- Diff: src/java/main/org/apache/zookeeper/server/ZooKeeperServer.java ---
@@ -303,15 +305,38 @@ public void loadData() throws IOException,
InterruptedException {
public void takeSnapshot(){
--- End diff --
I have some scenes need to take snapshot, for example
First, our major Zookeeper cluster was deployed in an AWS zone, some
observers running at a dozen IDC. We use this topological structure because
Zookeeper cluster is not friendly to multi-IDC deployment. Besize, our
zookeeper snapshot and transaction logs are huge, because some wrong client
usage that hard to fix in short time :(
Sometimes, we plan to maintains the major cluster, we have to start another
mirror cluster in same DC, and switch from the major cluster to the mirror
cluster. If we do it faster enough, the observer and client will not concern
the changes. That's why we need take snapshot to speed up the migration. If
something got wrong, we could switch back to the old cluster, lost some
transaction better than the whole system down.
Second, our backup policy need a daily/hourly offline backup, to AWS S3 or
other DC. I would like to take and upload a latest and clean snapshot, instead
of tar an old snapshot with a number of transaction logs.
Third, sometimes we need to deploy a new observer or a testing cluster in
different DC, we have to copy the latest snapshot offline, because Zookeeper
observer sync progress may become very slow, the TCP window could drop to
10-20KB/s in the 40-60% packet loss rate.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---