I'm experiencing a weird phenomenon. If I:

  1. Create a zip archive of some files on my Mac, either with the built in Archive Utility (Right ClickCompress "[Folder Name]") or with the p7zip command line utility for Mac (7za a [output].zip [input directory])
  2. Transfer this zip archive to a fresh, minimal installation of Debian Stretch, and try to extract it with either the unzip utility or the 7z command from the p7zip-full package

...then I will get an error that the zip is corrupted. It will extract, but some files will always be missing or incomplete.

I can transfer these same zip files back to my Mac, and they will extract fine. Similarly, if I make a zip archive under Debian (again, with either the zip utility or p7zip), my Mac has no trouble extracting it.

What is happening here? Is it possible to make a zip on my Mac that Debian will be able to open?

  • When you transfer, are you using external media such as USB Flash drive? If so, it might not be finished writing. – DrMoishe Pippik Aug 12 '18 at 20:27
  • @DrMoishePippik I'm using a flash drive, but I checked the md5 hash of the zip on both machines, and they line up. Furthermore, the problem occurs consistently across my many tries. – Wowfunhappy Aug 13 '18 at 14:29
  • Sorry... I was looking for a simple cause. It is odd -- I've created Zip archives on a number of systems, even old Solaris, and they've been cross-OS compatible. Check options when zipping, e.g archive format, compression method, dictionary and word size, etc. You might also try a differently formatted USB drive to see if that helps. – DrMoishe Pippik Aug 13 '18 at 18:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.