Skip to content

回复:自动备份 wallet.dat ​

原始发布页

打开来源页面
查看 1 个交叉存档

我一开始在另一个主题中发帖,不过我会在这里再说一遍,这个帖子似乎更切合这个话题。

备份方面的主要改进将是使用一个预先生成的密钥池,并在加载时重新扫描,从区块历史中捞取遗漏的交易。这样,一份备份在此后很长一段时间内都会有效。

nelisky,我刚才正想发出与你所说相同的想法。

设计一个 json-rpc 命令怎么样:它先锁定钱包、将其刷新写入磁盘,把 wallet.dat 复制到你指定的位置,然后解锁?这会是一个比密钥池更小的项目,所以也许可以先完成它。

复制文件最简单、可移植的方式是什么?Boost 里有这样的东西吗?

它应该叫什么名字?也许是: backupwallet <destination>

英文原文 ​

展开英文原文

I started posting in the other topic but I'll repeat here, this thread seems more specific to the topic.

The main backup improvement will be a pre-generated pool of keys and a rescan at load to scrape missed transactions from the block history. Then a backup will last forward for a long time.

I was starting to post the same idea you said nelisky.

How about a json-rpc command that locks the wallet, flushes it, copies wallet.dat to a location you specified, then unlocks it? That would be a smaller project than the pooled keys, so maybe it could be done first.

What's the simplest portable way to copy a file? Is there something in Boost?

What should it be named? maybe: backupwallet <destination>

为历史保存,为中文读者整理。每篇档案均附来源与英文原文。