【问题标题】:Gitlab backup restore Error --> tar: This does not look like a tar archiveGitlab备份还原错误-> tar:这看起来不像tar存档
【发布时间】:2018-12-29 09:50:59
【问题描述】:

我正在尝试使用以下命令在 Ubuntu 服务器上恢复 GitLab (8.16.1) 备份(备份由命令 sudo gitlab-rake gitlab:backup:create):

sudo gitlab-rake gitlab:backup:restore BACKUP=1493107454_2018_04_25_10.6.4-ce

它给了我错误:

gzip: stdin: not in gzip format
tar: This does not look like a tar archive
tar: Exiting with failure status due to previous errors

我的备份文件是 .tar 文件。

gzip 1.6 版

据我所知,在它恢复它首先提取的备份文件之前。
我不知道为什么提取的文件有扩展名.tar.gz

有人可以帮忙吗?

【问题讨论】:

    标签: linux ubuntu gitlab backup


    【解决方案1】:
    sudo gitlab-rake gitlab:backup:restore BACKUP=1493107454_2018_04_25_10.6.4-ce
    

    这意味着你应该有一个类似的文件:

    var/opt/gitlab/backups/1493107454_2018_04_25_10.6.4-ce_gitlab_backup.tar
    

    在同一文件夹中还有一个cat backup_information.yml,为您提供有关该备份的信息。
    如果该文件不是有效的存档,则可以解释错误消息。
    您可以将--trace 添加到 rake 命令以了解更多信息。

    【讨论】:

    • 是的,我在你说的这个位置有 .tar 文件。让我通过 --trace 来检查它。
    • 嘿@VonC,cat backup_information.yml 提供有关数据库的信息,gitlab 版本(8.16.1)tar_version:tar(GNU tar)1.28
    • @DarshanaPatel 好的,您当前的 GitLab 是同一版本,对吧?你系统上的 tar 还是 1.28?
    • yeah..GITLAB 版本和 tar 1.28 一样
    • 我只有gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/raketasks/…。独立于 rake 命令,您能否解压缩存档,只是为了检查它是否有效?
    猜你喜欢
    • 2014-02-03
    • 1970-01-01
    • 2011-03-20
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2016-11-27
    • 1970-01-01
    相关资源
    最近更新 更多