unzip command


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting unzip command
# 1  
Old 04-06-2010
unzip command

i want to know how to unzip a archive file by replacing the same folder with file name..

help me or not! SmilieImage
# 2  
Old 04-06-2010
it would be great if you post some of the file names...!!!

Try this : -

$uncompress <filename>

if the above command doesn't work then post the file names.
kandi.reddy
# 3  
Old 04-06-2010
XXX.tar.gz is the archive folder name.. want to replace this folder by extracting the data inside it and replacing at the same time.
# 4  
Old 04-06-2010
I think files are in gzip format, try using the foloowing command : -
$gunzip <file_name>
kandi.reddy
# 5  
Old 04-06-2010
it says command not found!
# 6  
Old 04-06-2010
Code:
$
$ ls -ltr a.txt
-rwx--x--x   1 kandir   staff        162 Mar  2 06:50 a.txt
$
$ gzip a.txt
$
$ ls -ltr a.txt*
-rwx--x--x   1 kandir   staff        141 Mar  2 06:50 a.txt.gz
$
$ gunzip a.txt.gz
$
$ ls -ltr a.txt*
-rwx--x--x   1 kandir   staff        162 Mar  2 06:50 a.txt
$


Last edited by pludi; 04-06-2010 at 03:45 AM.. Reason: code tags, please...
kandi.reddy
# 7  
Old 04-06-2010
thanks!
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

Unzip command

Hi I have a zip file at linux while unziping those files using unzip command in rare scenario it copy the 0 size file to the destination. These files are .so file with their soft link.It is happening for one of .so file. (2 Replies)
Discussion started by: AnkitMogha
2 Replies

2. Shell Programming and Scripting

Unzip the .zip file without using unzip utility in UNIX

I have .zip file, i want to list all the files archived in the zip file. unzip utility is not working for me in unix. Please help me resolve this issue Thanks ganesh. (3 Replies)
Discussion started by: Ganesh L
3 Replies

3. UNIX for Dummies Questions & Answers

UNIX unzip command

Hi, i transferred a .zip file from windows to Unix. i'm getting error while doing unzip in Unix like command : bash-3.2$ unzip ******.zip message : Archive: *******.zip End-of-central-directory signature not found. Either this file is not a zipfile, or it constitutes one disk... (2 Replies)
Discussion started by: asv444
2 Replies

4. UNIX for Advanced & Expert Users

Issue with unzip command

I have a zip file on the unix server. when I unzip it using unzip command(unzip -q filename.zip),then date values are retained properly for all the files but the time stamp is getting set to 12:00 AM for the files less than 6 months to the current date.Any help is highly appreciated .Thanks in... (2 Replies)
Discussion started by: vkishore1234
2 Replies

5. Shell Programming and Scripting

Issue with unzip command

I have a zip file on the unix server. when I unzip it using unzip command(unzip -q filename.zip) then the timestamp for the files less than 6 months to the current date are not retrieved instead It is setting the time as 12:00 AM to those files. I have some operations based on the datetimestamp of... (0 Replies)
Discussion started by: vkishore1234
0 Replies

6. Shell Programming and Scripting

Single command - unzip files from a tar command

I have a tar file that contains multiple .Z files. Hence I need to issue a tar command followed by a gzip command to fully extract the files. How do I do it in a single command? What I'm doing now is tar xvf a.tar (this will output 1.Z and 2.Z) gzip -d *.Z (to extract 1.Z and 2.Z) (9 Replies)
Discussion started by: ericlim
9 Replies

7. Shell Programming and Scripting

unzip command fails in ssh

I'm trying to run a set of commands on a remote machine using ssh in a shell script. One of the commands is unzip. But when the execution reaches this command, the script fails with an error that unzip is not found. Below is the code and the error snippet. sourceDir=$1 ; filename=$3 ; destDir=$2... (4 Replies)
Discussion started by: farahzaiba
4 Replies

8. Shell Programming and Scripting

How to Unzip a .ZIP file in Unix without using unzip cmd..?????

Hi All I have ftped a .ZIP file (zipped using WinZip in Windows) to my Unix server (HP-UX). I don't have unzip cmd available in my curent Unix version Please let me know any cmd in UNIX (other than unzip) using which I can unzip this .ZIP file . Please elaborate on the commands aval and... (5 Replies)
Discussion started by: sureshg_sampat
5 Replies

9. HP-UX

How to Unzip a .ZIP file in Unix without using unzip cmd..?????

Hi All I have ftped a .ZIP file (zipped using WinZip in Windows) to my Unix server (HP-UX). I don't have unzip cmd available in my curent Unix version Please let me know any cmd in UNIX (other than unzip) using which I can unzip this .ZIP file . Please elaborate on the commands aval and... (5 Replies)
Discussion started by: sureshg_sampat
5 Replies

10. UNIX for Dummies Questions & Answers

unzip command

The program asks, whether you want to replace, rename, etc., the file before unzipping. Is there any other command which can unzip the Winzip file in unix or any way so that this message will not come. As i have to run it thru the job scheduler. Thanks, Gaurav (1 Reply)
Discussion started by: gammit
1 Replies
Login or Register to Ask a Question