Urgent Help, Zip using winzip and unzip at Sun OS

The zip file which is created using winzip is tranferred from Windows server using Connect Direct ftp s/w to Sun OS box. When I try to unizp using unzip command getting following error. Any help is greatly appreciated.

$ unzip -ou EAgentCommissionsReport200602Locl1.zip
Archive:  EAgentCommissionsReport200602Locl1.zip
error [EAgentCommissionsReport200602Locl1.zip]:  missing 211 bytes in zipfile
  (attempting to process anyway)
error [EAgentCommissionsReport200602Locl1.zip]:  attempt to seek before beginning of zipfile
  (please check that you have transferred or created the zipfile in the
  appropriate BINARY mode and that you have compiled UnZip properly)
  (attempting to re-compensate)
file #1:  bad zipfile offset (local header sig):  274563
  (attempting to re-compensate)
file #1:  bad zipfile offset (local header sig):  274563
file #2:  bad zipfile offset (local header sig):  323116
file #3:  bad zipfile offset (local header sig):  899761
file #4:  bad zipfile offset (local header sig):  948527
file #5:  bad zipfile offset (local header sig):  1160108
file #6:  bad zipfile offset (local header sig):  1185826
LVL 1
ssunka01Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

nobusCommented:
the first thing i would try is recreating the zip file, it can simply be bad.
Can you open it on the windows server?
0
ssunka01Author Commented:
Yes, I can open in windows sever .
0
ssunka01Author Commented:
I recreated couple of times . Here is my batch script which will create zipfile

@ECHO OFF
if "%1"==""  goto SYNTAX

wzzip -a+rP \Groups\AS400\HORIZONLINK\ExternalAgentCommissionsReport%1.zip \Groups\AS400\HORIZONLINK\Local_Dealer\%1      

wzzip -a+rP \Groups\AS400\HORIZONLINK\ExternalAgentCommissionsReport%1.zip \Groups\AS400\HORIZONLINK\National_Accounts\%1
If ErrorLevel 1 Goto ErrMsg
   Echo No Known Errors
Goto Exit
:ErrMsg
Echo ***SERIOUS ERROR DETECTED***      
:SYNTAX
   echo usage is "EAgentCommissionsReport_zip.bat YYYYMM"
:Exit
0
Introducing Cloud Class® training courses

Tech changes fast. You can learn faster. That’s why we’re bringing professional training courses to Experts Exchange. With a subscription, you can access all the Cloud Class® courses to expand your education, prep for certifications, and get top-notch instructions.

nobusCommented:
did you try uninstalling the zip program on the sun server, and installing it again?
0
Mohammed HamadaSenior IT ConsultantCommented:
Try Reinstall winzip, or try using different zipping wares.. such as Rar programs..
0
nobusCommented:
or 7-zip :(free)   www.7-zip.org/
0
ssunka01Author Commented:
Any  more suggestions...
0
Mohammed HamadaSenior IT ConsultantCommented:
>>> missing 211 bytes in zipfile.... have you tried to repair the archive??
0
NopiusCommented:
try to zip on Windows with :
wzzip -ef -r -P

then unzip on Solaris without options:
unzip your_archive.zip
0
NopiusCommented:
try to 'unzip archive.zip' without any options first...
0
Joseph NyaemaIT ConsultantCommented:
When zipping the file using winzip, try using normal compression.
0
ssunka01Author Commented:
I do not  know how to repair the file, Can you plese suggest how I can do that ,
0
giltjrCommented:
Did you transfer the file as binary?  I have seen these problems when the file was transfered as ASCII.
0
ssunka01Author Commented:
giltjr / Nopius

Your options are throwing light , I am working on these options, will let you know the results. Thanks for your suggestions.
0
Mohammed HamadaSenior IT ConsultantCommented:
Check this trail version of zip repair...
http://www.ziprepair.com/
0
ssunka01Author Commented:
Finally able to unzip using unzip at sun os which are zipped at windows using winzip's command line interface command wzzip. zip file was transferred via Connect Direct s/w (Sterling Commerce product).  I am totally new to that s/w and involves some coding or configuration. The zip file was not transferring in binary mode. Finally with Connect Direct team member able to find to how to transfer binary mode.  

SUN OS unzip command unzipped the zip which was created in windows sucessfully without having any issue.

As a developer I do not have access to either to install or uninstall s/w on either machines. So I strict to the s/w which are avilable to use.  

Your suggestions are given options to keep on working so that I had many options to work on to resolve the issue
0
giltjrCommented:
Would strongly suggest that you work with the person that installed and setup Connect Direct.  I have used it, but I used it on an IBM mainframe under OS/390.  It was simple and easy for me, but I was also the person responsible for the install, setup, configuration, and setting up all of the jobs.  Plus the fact that I had used products like it before.

I would also suggest that you get the manuals, excuse me I mean documentation as most products don't ship real manuals any more.
0
scrathcyboyCommented:
On the windows box, you should be using TAR, not zip, because that is the native zip format understood by unix and Sun OS.  So TAR the files, transfer them, then UNTAR them at the other end.  You can use WINRAR for this on the PC side, then TAR/unTAR on the Sun side./
0
rsivanandanCommented:
Tar doesn't really compress, it only puts a wrapper on it. You could use tar and then zip it.

The files you zip on Windows can act weird when unzipped on *nix. First you need to run something like 'dos2unix' and the reverse as applicable.

I've faced a lot of problems with this while working with Cisco IPSMC/SecMon while testing 'em.

Cheers,
Rajesh
0
giltjrCommented:
The author has found the solution, which is when tranfering non-text file cross platform you must use binary.

As rsivanadan stated, tar by itself does not compress, you can use gzip/zip with tar to get it compressed, but it would NOT have solved the problem.  Even if he had used tar +gzip/zip and still tranfered in ASCII he still would have had the same problem.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Joseph NyaemaIT ConsultantCommented:
Ahhh....
Giltjr, you are being modest.

Without your input on binary file transfer, ssunka01 would not be anywhere close to solving the issue.

you deserve the credit here.
0
giltjrCommented:
That is up to ssunka01.

Binary was the trick (and sooner or later somebody else would have figured that out).  After working with customers doing file transfers cross platform (actually cross characters representation, EBCDIC to/from ASCII) for 20+ years binary vs. ASCII is the simplest problems to solve.

My last point was that it does not matter what he may have done to the file, as long as it was non-text, it must be transfered in binary or it gets hosed.  The TAR vs. ZIP is no argument at all.  Unix/Linux supports ZIP just as well as Windows supports TAR and TAR does NO compression (as rsivanandan stated) by itself.  It uses gzip, which happens to zip compatiable compression.  So using TAR will do nothing, but confuse the issue.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Operating Systems

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.