加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 综合聚焦 > 服务器 > Linux > 正文

linux – 当我的文件可能损坏时,如何从这个tar文件中提取?

发布时间:2020-12-13 17:18:25 所属栏目:Linux 来源:网络整理
导读:尝试从tar文件中提取所有文件时,我收到以下错误消息: tar: Skipping to next headertar: Error exit delayed from previous errors 在打印此错误消息之前,某些文件会正确提取,并且该过程会生成一个似乎包含其余存档的乱码文件.此存档中的所有文件都是文本文
尝试从tar文件中提取所有文件时,我收到以下错误消息:
tar: Skipping to next header
tar: Error exit delayed from previous errors

在打印此错误消息之前,某些文件会正确提取,并且该过程会生成一个似乎包含其余存档的乱码文件.此存档中的所有文件都是文本文件.

有什么我可以尝试恢复其余的文件?

解决方法

您可以使用-i选项尝试提取以忽略零:
The --ignore-zeros (-i) option causes tar to ignore blocks of zeros in
the archive. Normally a block of zeros indicates the end of the archive,but when reading a damaged archive,or one which was created by cat-ing
several archives together,this option allows tar to read the entire
archive. This option is not on by default because many versions of tar
write garbage after the zeroed blocks.

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读