Hi ,
I've written the following code to zip the big file
$dir_temp ="/home/etc/hst
zip -r $dir_temp/file_nm.zip $dir_temp/file_nm
The zip file has been created . When I try to UNZIP the file
with the following command
unzip file_nm.zip
The file got unzipped but created in the following path /home/etc/hst/home/etc/hst/file_nm
Please suggest me the correct unzip command so that the file got unzipped in the /home/etc/hst folder .
Thanks
How does your zip file look like ie structure ?
To unzip to another directory use:
unzip -d <DIR_NAME>
$dir_temp ="/home/etc/hst
is missing the double quotes at the end.
Make sure you add correct information here.
Instead of zip -r /incredibly/long/path/to/files ... try ( cd /incredibly/long ; zip -r path/to/files ... )
Thank You for your reply .
Is the following command works
unzip -d /home/etc/hst file_nm.zip
Sorry for missing the double quotes
Thank You