我从客户端收到了一个巨大的 .tar.gz 文件,其中包含大约 800 mb 的图像文件(未压缩时)。我们托管公司的 ftp 非常慢,因此在本地提取所有文件并通过 ftp 发送它们是不切实际的。我能够将 .tar.gz 文件 ftp 到我们的托管站点,但是当我 ssh 进入我的目录并尝试使用 unzip 时,它给了我这个错误:
[esthers@clients locations]$ unzip community_images.tar.gz
Archive: community_images.tar.gz
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.
note: community_images.tar.gz may be a plain executable, not an archive
unzip: cannot find zipfile directory in …Run Code Online (Sandbox Code Playgroud) 当我尝试解压缩.tgz存档时收到此错误消息:
$ tar -zxvf OVM_EL5U3_X86_EBIZ12.1.1_DB_VIS_PVM.tgz.1
gzip: stdin: not in gzip format
tar: Child returned status 1
tar: Error is not recoverable: exiting now
Run Code Online (Sandbox Code Playgroud)
如您所见,文件名以.tgz.1.
当文件名是时.tgz.0,它将被tar -zxvf命令解压缩而不会出错。
我正在学习 Linux 的基础知识和存档/压缩我偶然发现的 TAR 文件tar -xvf,并想知道它的作用。我检查了手册页,知道这x意味着提取和v冗长,但有什么作用f呢?