开发者

How to checksum an entire folder structure? [duplicate]

开发者 https://www.devze.com 2023-02-07 02:08 出处:网络
开发者_如何学运维This question already has answers here: Hashing a Tree Structure (11 answers) Closed 2 years ago.
开发者_如何学运维This question already has answers here: Hashing a Tree Structure (11 answers) Closed 2 years ago.

I have a large folder structure (i.e. 2-3GB worth of data) that needs to be verified against a separate structure on another drive.

Is there a way to checksum the entire directory structure to ensure that the two structures, as well as all file contents, match exactly?


A checksum won't help you in this circumstance, as the same process is going to be reading both sets of data. A digest value like that is useful when you have to communicate across processes or systems (in other words, different "things" are reading the different targets) so that you can pass a smaller set of data across the communication channel.

In your case, your application is going to be reading both, so a simple comparison is going to be your best bet.

0

精彩评论

暂无评论...
验证码 换一张
取 消