This question already has an answer here:

On linux, is there an easy way to recompress a zip file (changing compression-level) with preserving as most meta-data as possible (timestamps etc.)?

marked as duplicate by schily, Jeff Schaller, Christopher, msp9011, G-Man Dec 8 at 7:12

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • To clarify, when you say zip file you are referring to compression with the actual zip command, correct? – Peschke Dec 6 at 18:08
  • @Peschke Consider that we have an existing zip file with an unknown compression level. Now we'd like to 'change' the compression level of this file, e.g. to store-only (most likely, a decompression/recompression is required for this). I'm interested whether there's is any application/script which can do this as easy as possible, possibly by not changing any file meta data. It must not neccessarly use the 'zip' command. – MRalwasser Dec 6 at 19:17
  • Unzip should preserve timestamps by default so you can probably just unzip -> zip it with the parameters you want. You could always create a script or alias to do this as a one-liner. – f41lurizer Dec 6 at 19:35
  • MRalwasser, when you respond to a Comment, please click on edit and expand or refine the original post so all may see the latest information. Please do so, and advise which filesystem is in use, for different filesystems have different metadata available, and all so not store them in i-nodes. lostsaloon.com/technology/… and cs.columbia.edu/~smb/classes/s06-4118/l21.pdf may be helpful to you in understanding what you can access beyond the date and time of original archive creation. – K7AAY Dec 7 at 18:13

Any script which expands an archive back to its original collection of files, and then re-archives them with your preferred parameters, would work, so long as you collect the metadata (in your case, the original date and time of the first archive), then use touch to change the date and time of the new archive to match.

Not the answer you're looking for? Browse other questions tagged or ask your own question.