unzip 解壓大小限制
# unzip network.zip
Archive: network.zip
End-of-central-directory signature not found. Either this file is not
a zipfile, or it constitutes one disk of a multi-part archive. In the
latter case the central directory and zipfile comment will be found on
the last disk(s) of this archive.
unzip: cannot find zipfile directory in one of network.zip or
network.zip.zip, and cannot find network.zip.ZIP, period.
原因
根據unzip官網介紹:
For the UnZip 6.0 release, we want to give special credit to Myles Bennet, who started the job of supporting ZIP64 extensions and Large-File (> 2GiB) and provided a first (alpha-state) port.
也就是說:目前unzip只支持低於2GB的文件,大於2GB的還在開發中,和系統的位數有關。
PS:我們目前普遍使用的unzip還是2009年發佈的,真是經久彌堅!
解決
使用7z解決
下載最新7zip:https://sourceforge.net/projects/p7zip/files/p7zip/16.02/p7zip_16.02_x86_linux_bin.tar.bz2/download
// 解壓
tar -jxvf p7zip_16.02_x86_linux_bin.tar.bz2
// 安裝
# sh install.sh
- installing /usr/local/bin/7za
- installing /usr/local/bin/7zr
- installing /usr/local/bin/7z
- installing /usr/local/lib/p7zip/7zCon.sfx
- installing /usr/local/lib/p7zip/7z.so
- installing /usr/local/lib/p7zip/Codecs
- installing /usr/local/man/man1/7z.1
- installing /usr/local/man/man1/7za.1
- installing /usr/local/man/man1/7zr.1
- installing /usr/local/share/doc/p7zip/README
- installing /usr/local/share/doc/p7zip/ChangeLog
- installing HTML help in /usr/local/share/doc/p7zip/DOC
# 7za x network.zip
/usr/local/bin/7za: /usr/local/lib/p7zip/7za: /lib/ld-linux.so.2: bad ELF interpreter: No such file or directory
// 缺少依賴就裝
# sudo yum install glibc.i686
瞭解7z軟件:http://www.linuxdiyf.com/view_193969.html
再解壓
// 然後經過長時間的解壓就ok了
# 7za x network.zip
7-Zip (a) [32] 16.02 : Copyright (c) 1999-2016 Igor Pavlov : 2016-05-21
p7zip Version 16.02 (locale=en_US.UTF-8,Utf16=on,HugeFiles=on,32 bits,6 CPUs QEMU Virtual CPU version 1.5.3 (6D3),ASM)
Scanning the drive for archives:
1 file, 4294967296 bytes (4096 MiB)
Extracting archive: network.zip
ERRORS:
Unexpected end of archive
--
Path = network.zip
Type = zip
ERRORS:
Unexpected end of archive
Physical Size = 4294967296
Embedded Stub Size = 4
30% - network.csv
其中報了個錯:Unexpected end of archive
, 但依然在解壓,最後只接壓出一部分,確認是來源時壓縮得有問題,但是如果來源壓縮得正確,那也可以解壓正確。