我使用zip命令行和-r选项压缩了Mac上的一个目录。我将.zip scp到一个在Linux上运行的集群。
如果我尝试用以下命令解压缩.zip
tar -vxzf foo.zip
在我的机器上它可以工作。但是相同的命令在集群上不起作用。我得到了错误
gzip: stdin has more than one entry--rest ignored
tar: Child returned status 2
tar: Error is not recoverable: exiting now
我该如何解决这个问题?
在Linux中,有关这些版本的“tar”命令:
tar -tzf /path/to/filename.tar.gz # Show the content
tar -xzf /path/to/filename.tar.gz # Extract the content
观察这两个命令使用z选项,很好,它们按照预期工作。
通过man tar,关于z选项,它指示:
-z, --gzip, --gunzip, --ungzip
Filter the archive through gzip(1).
问题
为什么tar命令通过'z'选项使用gzip命令?
E
最近,我压缩了一个tar.gz文件,并认为我可以通过将tar.gz文件压缩成一个新的文件来进一步压缩它。
我用来压缩它的东西:
tar -czvf world.tar.gz world/
然后我做了:
tar -czvf world.tar.gz world.tar.gz
现在我无法使用普通命令解压缩它,因为它会产生以下错误:
gzip: stdin: not in gzip format
tar: Child returned status 1
tar: Error is not recoverable: exiting now
我有以下几个文件:
multiview_action.tgz.part-aa
multiview_action.tgz.part-ab
...
...
multiview_action.tgz.part-ap
我尝试了以下命令:
tar -zxvf multiview_action.tgz*
我得到了以下错误:
gzip: stdin: unexpected end of file
tar: Fin prématurée rencontrée dans l'archive.
tar: Error is not recoverable: exiting now
我下载了'jdk-7u55-linux-x64.tar.gz‘
当我执行以下命令解压缩时,
sudo tar xvzf jdk-7u55-linux-x64.tar.gz
也试过了,
sudo tar xvf jdk-7u55-linux-x64.tar.gz
sudo tar xf jdk-7u55-linux-x64.tar.gz
sudo tar -xvf jdk-7u55-linux-x64.tar.gz
但我终于犯了错误,
gzip: stdin: unexpected end of file
tar: Unexpected EOF in archive
tar: Unex
我正在尝试将java安装到我运行的服务器上。我从锂主机租用了一个服务器和域名,我正试图在那里创建一个网站,将用于通过solr搜索文件。我在Mac上通过SSH访问服务器的文件系统。我已经使用wget安装了solr,一切都运行得很好。但是,我不能安装java,这是solr工作所必需的。我尝试使用sudo、apt-get、yum和root@centos安装它,所有这些命令都返回一个错误,表明这些命令不存在。我可以使用wget下载适当的tar.gz文件。但是每当我尝试运行该命令时,都会发生错误
tar xxx-xxx-xx.tar.gz
我得到了错误:
gzip: stdin: not in gzip
寻找类似的解决方案,但在python中使用gzip或zlib。
这使得问题不起作用(参见第一个测试用例)
不是的副本,它不起作用(而且已经过时了)
这两个问题:和非常接近这个问题(尽管不同),但不幸的是,第一个问题没有有效的解决方案,而第二个问题根本没有任何答案。
我正在迭代从远程服务器接收的块块gzip字节,它看起来如下所示:
async with aiohttp.ClientSession() as session:
async with session.get(LINK) as response:
with open(FILE, "
大家好,我得到了这个异常:
The magic number in GZip header is not correct. Make sure you are passing in a GZip stream.
我所做的就是将文件解压缩为GZip,然后将其传递到流中,以将其传递到文件中。
using (FileStream fInStream = new FileStream(@"C:\Users\UNI\Desktop\FrostbyteDBUpdateProgram\FrostbyteDBUpdateProgram\bin\Debug\" + fileName, FileM
我正在使用带有boost::iostreams::filterimg_streambuf的boost::iostreams::gzip_decompressor来读取gzip文件。
我的一些文件包含zcat所说的trailing trash
% zcat somefile
data
data
data
gzip: somefile: decompression OK, trailing garbage ignored
我想要的是让boost gzip以同样的方式运行。
当尝试使用boost解压相同的文件时,使用以下函数,我得到了一个gzip_error异常(bad_header)
stati