0

So I have two servers with the same 10gb gzip file on each. On one server it unzips fine. On the other there are crc errors. The file sizes are the exact same. the systems are exactly the same versions of the OS, gzip verson is the same, hardware is the same, etc.

is there a way to get a checksum of some sort or compare the two files (without doing a diff between the two due to network latency) ?

I need to see or prove that is might be a disk or memory corruption problem.

EEAA
  • 109,363
  • 18
  • 175
  • 245
John Ingles
  • 119
  • 2
  • 7
  • I would, for some reason it doesn't let me log in with this 'anonymous' account. I will look into it. – John Ingles Feb 05 '12 at 05:23
  • 1
    Post a question about your account over in meta.serverfault.com - one of the mods should be able to get it sorted out. – EEAA Feb 05 '12 at 21:24

1 Answers1

10

Just run $ md5sum <filename> on each system, and verify the checksums match.

EEAA
  • 109,363
  • 18
  • 175
  • 245
  • Collisions wise, md5 is certainly not the best choice... – Déjà vu Feb 05 '12 at 07:44
  • 3
    @ring0: It's good enough under the circumstances. – womble Feb 05 '12 at 08:18
  • Oh, hell, in this scenario, "ls -l" and looking at file sizes is probably sufficient. It's implied that the file is the OP's own, and not something he pulled from a warez site. – cjc Feb 05 '12 at 13:53
  • @ring0: for checking for errors in transmission `crc32` is good enough. As the use has nothing to do with cryptography and is concerned only with file consistency *any* hash will do. As calculating MD5 is faster than SHA-1 or CRC32 (from `cksum`) it's a good suggestion. – Hubert Kario Feb 05 '12 at 22:34