HPE Community read-only access December 15, 2018
This is a maintenance upgrade. You will be able to read articles and posts, but not post or reply.
Hours:
Dec 15, 4:00 am to 10:00 am UTC
Dec 14, 10:00 pm CST to Dec 15, 4:00 am CST
Dec 14, 8:00 pm PST to Dec 15, 2:00 am PST
System Administration
cancel
Showing results for 
Search instead for 
Did you mean: 

unzip a zip file without "unzip" command

 
shashi kanth
Super Advisor

unzip a zip file without "unzip" command

As HP-UX won't ship with unzip by default (but i can install unzip by downloading from some place and install manually), is there anyway that i can unzip a zip file with some other utility in HP-UX ?
15 REPLIES

Re: unzip a zip file without "unzip" command

gunzip will handle only the first file in a .zip:
$ gunzip < 302602.zip > 302602.stuff
gunzip: stdin has more than one entry--rest ignored
Venkatesh BL
Honored Contributor

Re: unzip a zip file without "unzip" command

# gzip -d file.gz
Suraj K Sankari
Honored Contributor

Re: unzip a zip file without "unzip" command

Hi,

gzip -d filename also unzip a file

Suraj
shashi kanth
Super Advisor

Re: unzip a zip file without "unzip" command

# gzip -d hpux.parisc_11gR1_clusterware.zip
gzip: hpux.parisc_11gR1_clusterware.zip: unknown suffix -- ignored
Suraj K Sankari
Honored Contributor

Re: unzip a zip file without "unzip" command

Hi,

Please post the output of this command

#file hpux.parisc_11gR1_clusterware.zip

Suraj

Re: unzip a zip file without "unzip" command

>unknown suffix -- ignored

Naturally. That's why I used: < 302602.zip > 302602.stuff
shashi kanth
Super Advisor

Re: unzip a zip file without "unzip" command

# file hpux.parisc_11gR1_clusterware.zip
hpux.parisc_11gR1_clusterware.zip: awk program text
Suraj K Sankari
Honored Contributor

Re: unzip a zip file without "unzip" command

Hi,

I think it is not a zip file, it is a normal text file with .zip extension did u try with

head filename
or
vi filename

Suraj
Steven Schweda
Honored Contributor

Re: unzip a zip file without "unzip" command

> [...] i can install unzip by downloading
> from some place and install manually [...]

So why don't you do that? How hard do you
wish to make what should be an easy job?

> file hpux.parisc_11gR1_clusterware.zip
> hpux.parisc_11gR1_clusterware.zip: awk program text

> I think it is not a zip file, it is a
> normal text file with .zip extension did u
> try with

And I think that you should learn to spell
"you" correctly, and then run a simple
experiment before making foolish claims.

dy # uname -a
HP-UX dy B.11.11 U 9000/785 2012616114 unlimited-user license

dy # file unzip552.zip
unzip552.zip: awk program text

Which shows only that "file" doesn't know
everything.

Info-ZIP UnZip binary kits for almost any OS
are abundant, and you should be able to build
it from the sources, even using the (lame) HP
bundled C compiler. Why waste time fiddling
around with all this other nonsense?
shashi kanth
Super Advisor

Re: unzip a zip file without "unzip" command

> [...] i can install unzip by downloading
> from some place and install manually [...]

>So why don't you do that? How hard do you
>wish to make what should be an easy job? <<<


Steven,

I was installing some software in HP-UX, that software usually takes 3-4 hours, the software is in HP-UX package format (depots), so "swinstall" is busy for 3-4 hours.

In the mean time, i have couple of zip file which i want to unzip. I have not yet installed unzip*depot in the system, and i can't install unzip*depot until the software installation which i initiated before is completed.

So i was trying to get some help from this forum, that, is there any other utility which is equivalent of "GNU/unzip" in HP-UX which can understand the "GNU/unzip" used compression algorithm.

Thanks.

shashi kanth
Super Advisor

Re: unzip a zip file without "unzip" command

Thanks.
Steven Schweda
Honored Contributor

Re: unzip a zip file without "unzip" command

> [...] i can't install unzip*depot [...]

You don't _need_ to install UnZip from a
depot using swinstall.

http://www.info-zip.org/
http://www.info-zip.org/UnZip.html
ftp://ftp.info-zip.org/pub/infozip/
ftp://ftp.info-zip.org/pub/infozip/src/
ftp://ftp.info-zip.org/pub/infozip/src/unzip552.tgz

This should all be in the documentation:

mkdir unzip552
cd unzip552
gzip -dc ../unzip552.tgz | tar xf -
make -f unix/Makefile generic
./unzip -v

Then go wild.
Steven Schweda
Honored Contributor

Re: unzip a zip file without "unzip" command

And, for the record, "GNU/unzip" is gzip,
gunzip, gzcat (.gz). Info-ZIP UnZip is unzip
(.zip).

http://www.gzip.org/
Matti_Kurkela
Honored Contributor

Re: unzip a zip file without "unzip" command

A tip: if the system has a Java Development Kit installed, it should have the "jar" binary.
Look for /opt/java*/bin/jar.

The .jar archive format is compatible with .zip.

The command syntax of "jar" is the same as with the "tar" command.

To unzip a .zip file using jar:

jar xf file.zip

To view the list of contents:

jar tf file.zip

Note: if you use "jar" to create a .zip file, the jar command will auto-generate one extra file inside the .zip file, named META-INF/MANIFEST.MF. This is usually harmless, as the file will usually be empty or very small.

MK
MK
shashi kanth
Super Advisor

Re: unzip a zip file without "unzip" command

Thank you very much for this hint.