我第一次用S3为prometheus开始了thanos存储的实现,在执行thanos存储配置时我收到了这条错误消息。有人能帮我调试错误吗?
消息: level=info ts=2022-02-28T16:37:31.940118532Z caller=factory.go:49 msg=“加载桶配置”level=error ts=2022-02-28T16:37:31.940409873Z caller=main.go:132 err="yaml:解封组错误:\n第2行:字段加密在s3.Config\n创建s3 err=中找不到/project/cmd/thanos/store.go:250\nmain.registerStore.func1\n\t/home/circleci/project/cmd/thanos/store.go:195\nmain.main\n\t/home/circleci/project/cmd/thanos/main.go:130\nruntime.main\n\t/usr/local/go/src/runtime/proc.go:225\nruntime.goexit\n\t/usr/local/go/src/runtime/asm_amd64.s:1371\ncreate桶client\nmain.runStore\n\t/home/circleci/project/cmd/thanos/store.go:252\nmain.registerStore.func1\n\t/home/circleci/project/cmd/thanos/store.go:195\nmain.main\n\t/home/circleci/project/cmd/thanos/main.go:130\nruntime.main\n\t/usr/local/go/src/runtime/proc.go:225\nruntime.goexit\n\t/usr/local/go/src/runtime/asm_amd64.s:1371\n准备存储命令failed\nmain.main\n\t/home/circleci/project/cmd/thanos/main.go:132\nruntime.main\n\t/usr/local/go/src/runtime/proc.go:225\nruntime.goexit\n\t/usr/local/go/src/runtime/asm_amd64.s:1371“
发布于 2022-07-18 13:51:47
有两件事:
需要将标志传递给您设置的配置文件的--objstore.config-file=
然后,在您的配置中(缩写):
2)
type: S3
config:
sse_config:
type: ""
kms_key_id: ""
kms_encryption_context: {}
encryption_key: ""
sts_endpoint: ""https://thanos.io/tip/thanos/storage.md/#s3供参考。在我的经验中,“字段找不到”意味着要么是语法问题(缺少冒号、逗号、引号等等)或者,配置意外地遇到一个字段,该字段要求您在运行时显式地声明它。
https://stackoverflow.com/questions/71324798
复制相似问题