首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >由于crcmode未编译,Google cloud gsutil不一致地失败

由于crcmode未编译,Google cloud gsutil不一致地失败
EN

Stack Overflow用户
提问于 2020-07-12 20:29:20
回答 1查看 451关注 0票数 0

我正在使用google cloudbuild运行我的构建,并且我有一个从google存储桶复制缓存文件的步骤。

该步骤是使用来自"gcr.io/cloud-builders/ gsutil“的google的gsutil镜像。

构建会在每次“推送”到github存储库时自动运行。

这是步骤:

代码语言:javascript
复制
steps:
  - name: 'gcr.io/cloud-builders/gsutil'
    id: 'Loading gradle cache'
    entrypoint: 'sh'
    args:
      - '-c'
      - |
        fileName=file.tar.gz
        if gsutil -q stat gs://cache_${PROJECT_ID}/${fileName}; then
          echo 'Gradle cache found'
          cd /
          gsutil -m cp gs://cache_${PROJECT_ID}/${fileName} ${fileName}
          tar -xpzf ${fileName}
        else
          echo 'Gradle cache not found'
        fi
    volumes:
      - name: 'gradle_cache'
        path: /root/.gradle
    waitFor: ['-']
    timeout: 60s

问题是,由于crcmod未编译,它有时会通过,有时会失败,出现以下错误:

代码语言:javascript
复制
CommandException:
Downloading this composite object requires integrity checking with CRC32c,
but your crcmod installation isn't using the module's C extension, so the
hash computation will likely throttle download performance. For help
installing the extension, please see "gsutil help crcmod".

To download regardless of crcmod performance or to skip slow integrity
checks, see the "check_hashes" option in your boto config file.
CommandException: 1 file/object could not be transferred.

这个错误发生在4-5天前。你知道怎么解决这个问题吗?

谢谢

EN

回答 1

Stack Overflow用户

发布于 2020-07-13 08:12:35

参见gsutil help crcmod。如果您想要下载复合对象,则需要安装已编译的crcmod。(也可以禁用校验和,但这不是一个好主意--您不会检测到数据损坏。)

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/62861084

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档