Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I've run the following command: zip -r -s 200M myzip folder to compress the folder into multiple zip files (200M each).

I now have a small myzip.zip (7mb) file and the files:

myzip.z01
myzip.z02
myzip.z03
...

and so on.

The issue is that I cannot unzip the content. I'm running unzip unix archive.zip but I get "bad zipfile offset (lseek)". Furthermore, I need to extract them in Windows environment as well, and there I only have Windows 7 extractor I guess.

thanks

share|improve this question

2 Answers 2

up vote 1 down vote accepted

Judging from your previous questions, you're using OS X with Zip 3.0 and UnZip 5.52. If I zip some files with

zip -s 5m -r test test/

I get several files, including one with the .zip extension. Running

unzip test.zip

works just fine and deflates all the contents.

Zip has the problem that some files can not be read on other systems, that's why I would suggest trying different programs like @Sandeep suggested.

Fixing archive

You can also try to fix the original:

zip -F archive.zip --out archive-fixed
zip -FF archive.zip --out archive-fixed

Alternatives

I don't know if you really need to use Zip, but I think you might be better off using Tar and GZip.

tar cvf archive.tar.gz directory
split --line-bytes=600m archive.tar.gz part

and then again concatenate the files, either using cat on Unix-like systems or copy on Windows.

cat part* > archive.tar.gz
copy /b part1+part2 archive.tar.gz

Extract the file on Unix systems by double clicking. 7Zip on Windows is a good tool for that purpose.

share|improve this answer
    
So what compression format you suggest. Yeah exactly I'm compressing on mac and uncompressing on Windows. –  Patrick Apr 19 '11 at 12:51
    
@Patrick I added Tar+GZip as an alternative. You might want to give it a try! –  slhck Apr 19 '11 at 12:53

In Windows you can try

All work well with extraction, some work and some don't with what you're trying to achieve just trial and error.

share|improve this answer
    
I'm now using 7Zip and I get "unsupported compression method" error. I will try Winrar, but do you think it is the extraction software, or rather a bad compression ? –  Patrick Apr 19 '11 at 12:30
    
It is most likely bad compression, but some software can handle corrupted files, such as Winrar, it has the possibility to fix corrupt archives. –  Sandeep Bansal Apr 19 '11 at 17:14

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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